InΒ [Β ]:
# This Python 3 environment comes with many helpful analytics libraries installed
# It is defined by the kaggle/python Docker image: https://github.com/kaggle/docker-python
# For example, here's several helpful packages to load

import numpy as np # linear algebra
import pandas as pd # data processing, CSV file I/O (e.g. pd.read_csv)

# Input data files are available in the read-only "../input/" directory
# For example, running this (by clicking run or pressing Shift+Enter) will list all files under the input directory

import os
for dirname, _, filenames in os.walk('/kaggle/input'):
    for filename in filenames:
        print(os.path.join(dirname, filename))

# You can write up to 20GB to the current directory (/kaggle/working/) that gets preserved as output when you create a version using "Save & Run All"
# You can also write temporary files to /kaggle/temp/, but they won't be saved outside of the current session
InΒ [Β ]:
 
InΒ [1]:
pip install ultralytics
Collecting ultralytics
  Downloading ultralytics-8.3.147-py3-none-any.whl.metadata (37 kB)
Requirement already satisfied: numpy>=1.23.0 in /opt/conda/lib/python3.10/site-packages (from ultralytics) (1.26.4)
Requirement already satisfied: matplotlib>=3.3.0 in /opt/conda/lib/python3.10/site-packages (from ultralytics) (3.7.5)
Requirement already satisfied: opencv-python>=4.6.0 in /opt/conda/lib/python3.10/site-packages (from ultralytics) (4.10.0.84)
Requirement already satisfied: pillow>=7.1.2 in /opt/conda/lib/python3.10/site-packages (from ultralytics) (10.3.0)
Requirement already satisfied: pyyaml>=5.3.1 in /opt/conda/lib/python3.10/site-packages (from ultralytics) (6.0.2)
Requirement already satisfied: requests>=2.23.0 in /opt/conda/lib/python3.10/site-packages (from ultralytics) (2.32.3)
Requirement already satisfied: scipy>=1.4.1 in /opt/conda/lib/python3.10/site-packages (from ultralytics) (1.14.1)
Requirement already satisfied: torch>=1.8.0 in /opt/conda/lib/python3.10/site-packages (from ultralytics) (2.4.0)
Requirement already satisfied: torchvision>=0.9.0 in /opt/conda/lib/python3.10/site-packages (from ultralytics) (0.19.0)
Requirement already satisfied: tqdm>=4.64.0 in /opt/conda/lib/python3.10/site-packages (from ultralytics) (4.66.4)
Requirement already satisfied: psutil in /opt/conda/lib/python3.10/site-packages (from ultralytics) (5.9.3)
Requirement already satisfied: py-cpuinfo in /opt/conda/lib/python3.10/site-packages (from ultralytics) (9.0.0)
Requirement already satisfied: pandas>=1.1.4 in /opt/conda/lib/python3.10/site-packages (from ultralytics) (2.2.3)
Collecting ultralytics-thop>=2.0.0 (from ultralytics)
  Downloading ultralytics_thop-2.0.14-py3-none-any.whl.metadata (9.4 kB)
Requirement already satisfied: contourpy>=1.0.1 in /opt/conda/lib/python3.10/site-packages (from matplotlib>=3.3.0->ultralytics) (1.2.1)
Requirement already satisfied: cycler>=0.10 in /opt/conda/lib/python3.10/site-packages (from matplotlib>=3.3.0->ultralytics) (0.12.1)
Requirement already satisfied: fonttools>=4.22.0 in /opt/conda/lib/python3.10/site-packages (from matplotlib>=3.3.0->ultralytics) (4.53.0)
Requirement already satisfied: kiwisolver>=1.0.1 in /opt/conda/lib/python3.10/site-packages (from matplotlib>=3.3.0->ultralytics) (1.4.5)
Requirement already satisfied: packaging>=20.0 in /opt/conda/lib/python3.10/site-packages (from matplotlib>=3.3.0->ultralytics) (21.3)
Requirement already satisfied: pyparsing>=2.3.1 in /opt/conda/lib/python3.10/site-packages (from matplotlib>=3.3.0->ultralytics) (3.1.2)
Requirement already satisfied: python-dateutil>=2.7 in /opt/conda/lib/python3.10/site-packages (from matplotlib>=3.3.0->ultralytics) (2.9.0.post0)
Requirement already satisfied: pytz>=2020.1 in /opt/conda/lib/python3.10/site-packages (from pandas>=1.1.4->ultralytics) (2024.1)
Requirement already satisfied: tzdata>=2022.7 in /opt/conda/lib/python3.10/site-packages (from pandas>=1.1.4->ultralytics) (2024.1)
Requirement already satisfied: charset-normalizer<4,>=2 in /opt/conda/lib/python3.10/site-packages (from requests>=2.23.0->ultralytics) (3.3.2)
Requirement already satisfied: idna<4,>=2.5 in /opt/conda/lib/python3.10/site-packages (from requests>=2.23.0->ultralytics) (3.7)
Requirement already satisfied: urllib3<3,>=1.21.1 in /opt/conda/lib/python3.10/site-packages (from requests>=2.23.0->ultralytics) (1.26.18)
Requirement already satisfied: certifi>=2017.4.17 in /opt/conda/lib/python3.10/site-packages (from requests>=2.23.0->ultralytics) (2024.6.2)
Requirement already satisfied: filelock in /opt/conda/lib/python3.10/site-packages (from torch>=1.8.0->ultralytics) (3.15.1)
Requirement already satisfied: typing-extensions>=4.8.0 in /opt/conda/lib/python3.10/site-packages (from torch>=1.8.0->ultralytics) (4.12.2)
Requirement already satisfied: sympy in /opt/conda/lib/python3.10/site-packages (from torch>=1.8.0->ultralytics) (1.13.3)
Requirement already satisfied: networkx in /opt/conda/lib/python3.10/site-packages (from torch>=1.8.0->ultralytics) (3.3)
Requirement already satisfied: jinja2 in /opt/conda/lib/python3.10/site-packages (from torch>=1.8.0->ultralytics) (3.1.4)
Requirement already satisfied: fsspec in /opt/conda/lib/python3.10/site-packages (from torch>=1.8.0->ultralytics) (2024.6.0)
Requirement already satisfied: six>=1.5 in /opt/conda/lib/python3.10/site-packages (from python-dateutil>=2.7->matplotlib>=3.3.0->ultralytics) (1.16.0)
Requirement already satisfied: MarkupSafe>=2.0 in /opt/conda/lib/python3.10/site-packages (from jinja2->torch>=1.8.0->ultralytics) (2.1.5)
Requirement already satisfied: mpmath<1.4,>=1.1.0 in /opt/conda/lib/python3.10/site-packages (from sympy->torch>=1.8.0->ultralytics) (1.3.0)
Downloading ultralytics-8.3.147-py3-none-any.whl (1.0 MB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 1.0/1.0 MB 33.0 MB/s eta 0:00:00
Downloading ultralytics_thop-2.0.14-py3-none-any.whl (26 kB)
Installing collected packages: ultralytics-thop, ultralytics
Successfully installed ultralytics-8.3.147 ultralytics-thop-2.0.14
Note: you may need to restart the kernel to use updated packages.
InΒ [2]:
!pip install roboflow

from roboflow import Roboflow
rf = Roboflow(api_key="GZBlBPlRdRvB6uR7BqaS")
project = rf.workspace("detection-e83li").project("smokeandfire")
version = project.version(2)
dataset = version.download("yolov8")
Collecting roboflow
  Downloading roboflow-1.1.65-py3-none-any.whl.metadata (9.7 kB)
Requirement already satisfied: certifi in /opt/conda/lib/python3.10/site-packages (from roboflow) (2024.6.2)
Requirement already satisfied: idna==3.7 in /opt/conda/lib/python3.10/site-packages (from roboflow) (3.7)
Requirement already satisfied: cycler in /opt/conda/lib/python3.10/site-packages (from roboflow) (0.12.1)
Requirement already satisfied: kiwisolver>=1.3.1 in /opt/conda/lib/python3.10/site-packages (from roboflow) (1.4.5)
Requirement already satisfied: matplotlib in /opt/conda/lib/python3.10/site-packages (from roboflow) (3.7.5)
Requirement already satisfied: numpy>=1.18.5 in /opt/conda/lib/python3.10/site-packages (from roboflow) (1.26.4)
Requirement already satisfied: opencv-python-headless==4.10.0.84 in /opt/conda/lib/python3.10/site-packages (from roboflow) (4.10.0.84)
Requirement already satisfied: Pillow>=7.1.2 in /opt/conda/lib/python3.10/site-packages (from roboflow) (10.3.0)
Collecting pillow-heif>=0.18.0 (from roboflow)
  Downloading pillow_heif-0.22.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata (9.6 kB)
Requirement already satisfied: python-dateutil in /opt/conda/lib/python3.10/site-packages (from roboflow) (2.9.0.post0)
Requirement already satisfied: python-dotenv in /opt/conda/lib/python3.10/site-packages (from roboflow) (1.0.1)
Requirement already satisfied: requests in /opt/conda/lib/python3.10/site-packages (from roboflow) (2.32.3)
Requirement already satisfied: six in /opt/conda/lib/python3.10/site-packages (from roboflow) (1.16.0)
Requirement already satisfied: urllib3>=1.26.6 in /opt/conda/lib/python3.10/site-packages (from roboflow) (1.26.18)
Requirement already satisfied: tqdm>=4.41.0 in /opt/conda/lib/python3.10/site-packages (from roboflow) (4.66.4)
Requirement already satisfied: PyYAML>=5.3.1 in /opt/conda/lib/python3.10/site-packages (from roboflow) (6.0.2)
Requirement already satisfied: requests-toolbelt in /opt/conda/lib/python3.10/site-packages (from roboflow) (0.10.1)
Collecting filetype (from roboflow)
  Downloading filetype-1.2.0-py2.py3-none-any.whl.metadata (6.5 kB)
Requirement already satisfied: contourpy>=1.0.1 in /opt/conda/lib/python3.10/site-packages (from matplotlib->roboflow) (1.2.1)
Requirement already satisfied: fonttools>=4.22.0 in /opt/conda/lib/python3.10/site-packages (from matplotlib->roboflow) (4.53.0)
Requirement already satisfied: packaging>=20.0 in /opt/conda/lib/python3.10/site-packages (from matplotlib->roboflow) (21.3)
Requirement already satisfied: pyparsing>=2.3.1 in /opt/conda/lib/python3.10/site-packages (from matplotlib->roboflow) (3.1.2)
Requirement already satisfied: charset-normalizer<4,>=2 in /opt/conda/lib/python3.10/site-packages (from requests->roboflow) (3.3.2)
Downloading roboflow-1.1.65-py3-none-any.whl (85 kB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 85.8/85.8 kB 3.9 MB/s eta 0:00:00
Downloading pillow_heif-0.22.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (7.8 MB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 7.8/7.8 MB 93.2 MB/s eta 0:00:00:00:0100:01
Downloading filetype-1.2.0-py2.py3-none-any.whl (19 kB)
Installing collected packages: filetype, pillow-heif, roboflow
Successfully installed filetype-1.2.0 pillow-heif-0.22.0 roboflow-1.1.65
loading Roboflow workspace...
loading Roboflow project...
Downloading Dataset Version Zip in smokeandfire-2 to yolov8:: 100%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| 381019/381019 [00:11<00:00, 32475.34it/s]

Extracting Dataset Version Zip to smokeandfire-2 in yolov8:: 100%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| 19708/19708 [00:02<00:00, 8893.65it/s] 
Creating new Ultralytics Settings v0.0.6 file βœ… 
View Ultralytics Settings with 'yolo settings' or at '/root/.config/Ultralytics/settings.json'
Update Settings with 'yolo settings key=value', i.e. 'yolo settings runs_dir=path/to/dir'. For help see https://docs.ultralytics.com/quickstart/#ultralytics-settings.

YOLO v8- MediumΒΆ

InΒ [4]:
!yolo train model=yolov8m.pt data='/kaggle/working/smokeandfire-2/data.yaml' epochs=20 imgsz=640 batch=32  augment=True
Downloading https://github.com/ultralytics/assets/releases/download/v8.3.0/yolov8m.pt to 'yolov8m.pt'...
100%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| 49.7M/49.7M [00:00<00:00, 329MB/s]
Ultralytics 8.3.70 πŸš€ Python-3.10.14 torch-2.4.0 CUDA:0 (Tesla P100-PCIE-16GB, 16269MiB)
engine/trainer: task=detect, mode=train, model=yolov8m.pt, data=/kaggle/working/smokeandfire-2/data.yaml, epochs=20, time=None, patience=100, batch=32, imgsz=640, save=True, save_period=-1, cache=False, device=None, workers=8, project=None, name=train, exist_ok=False, pretrained=True, optimizer=auto, verbose=True, seed=0, deterministic=True, single_cls=False, rect=False, cos_lr=False, close_mosaic=10, resume=False, amp=True, fraction=1.0, profile=False, freeze=None, multi_scale=False, overlap_mask=True, mask_ratio=4, dropout=0.0, val=True, split=val, save_json=False, save_hybrid=False, conf=None, iou=0.7, max_det=300, half=False, dnn=False, plots=True, source=None, vid_stride=1, stream_buffer=False, visualize=False, augment=True, agnostic_nms=False, classes=None, retina_masks=False, embed=None, show=False, save_frames=False, save_txt=False, save_conf=False, save_crop=False, show_labels=True, show_conf=True, show_boxes=True, line_width=None, format=torchscript, keras=False, optimize=False, int8=False, dynamic=False, simplify=True, opset=None, workspace=None, nms=False, lr0=0.01, lrf=0.01, momentum=0.937, weight_decay=0.0005, warmup_epochs=3.0, warmup_momentum=0.8, warmup_bias_lr=0.1, box=7.5, cls=0.5, dfl=1.5, pose=12.0, kobj=1.0, nbs=64, hsv_h=0.015, hsv_s=0.7, hsv_v=0.4, degrees=0.0, translate=0.1, scale=0.5, shear=0.0, perspective=0.0, flipud=0.0, fliplr=0.5, bgr=0.0, mosaic=1.0, mixup=0.0, copy_paste=0.0, copy_paste_mode=flip, auto_augment=randaugment, erasing=0.4, crop_fraction=1.0, cfg=None, tracker=botsort.yaml, save_dir=runs/detect/train
Downloading https://ultralytics.com/assets/Arial.ttf to '/root/.config/Ultralytics/Arial.ttf'...
100%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| 755k/755k [00:00<00:00, 22.0MB/s]
Overriding model.yaml nc=80 with nc=2

                   from  n    params  module                                       arguments                     
  0                  -1  1      1392  ultralytics.nn.modules.conv.Conv             [3, 48, 3, 2]                 
  1                  -1  1     41664  ultralytics.nn.modules.conv.Conv             [48, 96, 3, 2]                
  2                  -1  2    111360  ultralytics.nn.modules.block.C2f             [96, 96, 2, True]             
  3                  -1  1    166272  ultralytics.nn.modules.conv.Conv             [96, 192, 3, 2]               
  4                  -1  4    813312  ultralytics.nn.modules.block.C2f             [192, 192, 4, True]           
  5                  -1  1    664320  ultralytics.nn.modules.conv.Conv             [192, 384, 3, 2]              
  6                  -1  4   3248640  ultralytics.nn.modules.block.C2f             [384, 384, 4, True]           
  7                  -1  1   1991808  ultralytics.nn.modules.conv.Conv             [384, 576, 3, 2]              
  8                  -1  2   3985920  ultralytics.nn.modules.block.C2f             [576, 576, 2, True]           
  9                  -1  1    831168  ultralytics.nn.modules.block.SPPF            [576, 576, 5]                 
 10                  -1  1         0  torch.nn.modules.upsampling.Upsample         [None, 2, 'nearest']          
 11             [-1, 6]  1         0  ultralytics.nn.modules.conv.Concat           [1]                           
 12                  -1  2   1993728  ultralytics.nn.modules.block.C2f             [960, 384, 2]                 
 13                  -1  1         0  torch.nn.modules.upsampling.Upsample         [None, 2, 'nearest']          
 14             [-1, 4]  1         0  ultralytics.nn.modules.conv.Concat           [1]                           
 15                  -1  2    517632  ultralytics.nn.modules.block.C2f             [576, 192, 2]                 
 16                  -1  1    332160  ultralytics.nn.modules.conv.Conv             [192, 192, 3, 2]              
 17            [-1, 12]  1         0  ultralytics.nn.modules.conv.Concat           [1]                           
 18                  -1  2   1846272  ultralytics.nn.modules.block.C2f             [576, 384, 2]                 
 19                  -1  1   1327872  ultralytics.nn.modules.conv.Conv             [384, 384, 3, 2]              
 20             [-1, 9]  1         0  ultralytics.nn.modules.conv.Concat           [1]                           
 21                  -1  2   4207104  ultralytics.nn.modules.block.C2f             [960, 576, 2]                 
 22        [15, 18, 21]  1   3776854  ultralytics.nn.modules.head.Detect           [2, [192, 384, 576]]          
Model summary: 295 layers, 25,857,478 parameters, 25,857,462 gradients, 79.1 GFLOPs

Transferred 469/475 items from pretrained weights
TensorBoard: Start with 'tensorboard --logdir runs/detect/train', view at http://localhost:6006/
Freezing layer 'model.22.dfl.conv.weight'
AMP: running Automatic Mixed Precision (AMP) checks...
Downloading https://github.com/ultralytics/assets/releases/download/v8.3.0/yolo11n.pt to 'yolo11n.pt'...
100%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| 5.35M/5.35M [00:00<00:00, 97.3MB/s]
AMP: checks passed βœ…
train: Scanning /kaggle/working/smokeandfire-2/train/labels... 8243 images, 11 b
train: New cache created: /kaggle/working/smokeandfire-2/train/labels.cache
WARNING ⚠️ Box and segment counts should be equal, but got len(segments) = 12, len(boxes) = 16365. To resolve this only boxes will be used and all segments will be removed. To avoid this please supply either a detect or segment dataset, not a detect-segment mixed dataset.
/opt/conda/lib/python3.10/site-packages/albumentations/__init__.py:24: UserWarning: A new version of Albumentations is available: 2.0.2 (you have 1.4.21). Upgrade using: pip install -U albumentations. To disable automatic update checks, set the environment variable NO_ALBUMENTATIONS_UPDATE to 1.
  check_for_updates()
albumentations: Blur(p=0.01, blur_limit=(3, 7)), MedianBlur(p=0.01, blur_limit=(3, 7)), ToGray(p=0.01, num_output_channels=3, method='weighted_average'), CLAHE(p=0.01, clip_limit=(1.0, 4.0), tile_grid_size=(8, 8))
/opt/conda/lib/python3.10/multiprocessing/popen_fork.py:66: RuntimeWarning: os.fork() was called. os.fork() is incompatible with multithreaded code, and JAX is multithreaded, so this will likely lead to a deadlock.
  self.pid = os.fork()
val: Scanning /kaggle/working/smokeandfire-2/valid/labels... 1062 images, 3 back
val: New cache created: /kaggle/working/smokeandfire-2/valid/labels.cache
/opt/conda/lib/python3.10/multiprocessing/popen_fork.py:66: RuntimeWarning: os.fork() was called. os.fork() is incompatible with multithreaded code, and JAX is multithreaded, so this will likely lead to a deadlock.
  self.pid = os.fork()
Plotting labels to runs/detect/train/labels.jpg... 
optimizer: 'optimizer=auto' found, ignoring 'lr0=0.01' and 'momentum=0.937' and determining best 'optimizer', 'lr0' and 'momentum' automatically... 
optimizer: AdamW(lr=0.001667, momentum=0.9) with parameter groups 77 weight(decay=0.0), 84 weight(decay=0.0005), 83 bias(decay=0.0)
TensorBoard: model graph visualization added βœ…
Image sizes 640 train, 640 val
Using 4 dataloader workers
Logging results to runs/detect/train
Starting training for 20 epochs...

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       1/20      14.4G      1.478       1.91      1.611        111        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.397      0.454      0.366      0.216

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       2/20      14.9G      1.486      1.699      1.629         68        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.677      0.564      0.604      0.419

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       3/20        15G      1.425      1.561      1.586         42        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.724      0.643      0.689      0.498

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       4/20        15G      1.375      1.481      1.549         67        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.815      0.688      0.744      0.552

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       5/20      15.1G      1.312      1.359      1.501         69        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.841      0.756      0.795        0.6

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       6/20      15.1G      1.281      1.302       1.48         65        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.844      0.766      0.796      0.605

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       7/20      15.1G      1.235      1.236      1.449         66        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.858      0.798      0.813      0.628

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       8/20      15.1G      1.209      1.185       1.43         54        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.856      0.816      0.828      0.631

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       9/20      15.1G      1.175      1.136      1.412         49        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.858      0.809      0.826      0.647

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      10/20      15.1G       1.17      1.127      1.415         79        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.867      0.825      0.841      0.653
Closing dataloader mosaic
albumentations: Blur(p=0.01, blur_limit=(3, 7)), MedianBlur(p=0.01, blur_limit=(3, 7)), ToGray(p=0.01, num_output_channels=3, method='weighted_average'), CLAHE(p=0.01, clip_limit=(1.0, 4.0), tile_grid_size=(8, 8))
/opt/conda/lib/python3.10/multiprocessing/popen_fork.py:66: RuntimeWarning: os.fork() was called. os.fork() is incompatible with multithreaded code, and JAX is multithreaded, so this will likely lead to a deadlock.
  self.pid = os.fork()

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      11/20        15G       1.21        1.1       1.46         41        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.873      0.835      0.837      0.652

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      12/20      15.1G      1.186       1.05      1.434         38        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.869      0.838      0.842      0.657

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      13/20        15G      1.166      1.011      1.416         34        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.879      0.829      0.841      0.664

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      14/20        15G      1.139      0.984      1.402         39        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.888       0.84      0.861       0.68

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      15/20      15.1G      1.108     0.9416      1.384         25        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.876      0.866      0.869      0.692

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      16/20        15G       1.09        0.9      1.367         35        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.897      0.853      0.863       0.69

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      17/20      15.1G      1.058     0.8724      1.347         45        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.891      0.851      0.867      0.694

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      18/20      15.1G      1.034     0.8338      1.328         33        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.887       0.86      0.872      0.703

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      19/20      15.1G      1.011     0.7975      1.306         31        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.885      0.869      0.869        0.7

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      20/20        15G     0.9823     0.7615      1.291         37        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.898      0.863      0.877      0.709

20 epochs completed in 1.651 hours.
Optimizer stripped from runs/detect/train/weights/last.pt, 52.0MB
Optimizer stripped from runs/detect/train/weights/best.pt, 52.0MB

Validating runs/detect/train/weights/best.pt...
Ultralytics 8.3.70 πŸš€ Python-3.10.14 torch-2.4.0 CUDA:0 (Tesla P100-PCIE-16GB, 16269MiB)
Model summary (fused): 218 layers, 25,840,918 parameters, 0 gradients, 78.7 GFLOPs
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.894       0.86      0.876      0.711
                  Fire        859       1320      0.909      0.943      0.932       0.76
                 Smoke        559        761      0.878      0.777      0.819      0.661
Speed: 0.1ms preprocess, 22.1ms inference, 0.0ms loss, 0.7ms postprocess per image
Results saved to runs/detect/train
πŸ’‘ Learn more at https://docs.ultralytics.com/modes/train

yoloV8-nanoΒΆ

InΒ [3]:
!yolo train model=yolov8n.pt data='/kaggle/working/smokeandfire-2/data.yaml' epochs=80 imgsz=640 batch=32  augment=True
Downloading https://github.com/ultralytics/assets/releases/download/v8.3.0/yolov8n.pt to 'yolov8n.pt'...
100%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| 6.25M/6.25M [00:00<00:00, 175MB/s]
Ultralytics 8.3.70 πŸš€ Python-3.10.14 torch-2.4.0 CUDA:0 (Tesla P100-PCIE-16GB, 16269MiB)
engine/trainer: task=detect, mode=train, model=yolov8n.pt, data=/kaggle/working/smokeandfire-2/data.yaml, epochs=80, time=None, patience=100, batch=32, imgsz=640, save=True, save_period=-1, cache=False, device=None, workers=8, project=None, name=train, exist_ok=False, pretrained=True, optimizer=auto, verbose=True, seed=0, deterministic=True, single_cls=False, rect=False, cos_lr=False, close_mosaic=10, resume=False, amp=True, fraction=1.0, profile=False, freeze=None, multi_scale=False, overlap_mask=True, mask_ratio=4, dropout=0.0, val=True, split=val, save_json=False, save_hybrid=False, conf=None, iou=0.7, max_det=300, half=False, dnn=False, plots=True, source=None, vid_stride=1, stream_buffer=False, visualize=False, augment=True, agnostic_nms=False, classes=None, retina_masks=False, embed=None, show=False, save_frames=False, save_txt=False, save_conf=False, save_crop=False, show_labels=True, show_conf=True, show_boxes=True, line_width=None, format=torchscript, keras=False, optimize=False, int8=False, dynamic=False, simplify=True, opset=None, workspace=None, nms=False, lr0=0.01, lrf=0.01, momentum=0.937, weight_decay=0.0005, warmup_epochs=3.0, warmup_momentum=0.8, warmup_bias_lr=0.1, box=7.5, cls=0.5, dfl=1.5, pose=12.0, kobj=1.0, nbs=64, hsv_h=0.015, hsv_s=0.7, hsv_v=0.4, degrees=0.0, translate=0.1, scale=0.5, shear=0.0, perspective=0.0, flipud=0.0, fliplr=0.5, bgr=0.0, mosaic=1.0, mixup=0.0, copy_paste=0.0, copy_paste_mode=flip, auto_augment=randaugment, erasing=0.4, crop_fraction=1.0, cfg=None, tracker=botsort.yaml, save_dir=runs/detect/train
Downloading https://ultralytics.com/assets/Arial.ttf to '/root/.config/Ultralytics/Arial.ttf'...
100%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| 755k/755k [00:00<00:00, 46.1MB/s]
Overriding model.yaml nc=80 with nc=2

                   from  n    params  module                                       arguments                     
  0                  -1  1       464  ultralytics.nn.modules.conv.Conv             [3, 16, 3, 2]                 
  1                  -1  1      4672  ultralytics.nn.modules.conv.Conv             [16, 32, 3, 2]                
  2                  -1  1      7360  ultralytics.nn.modules.block.C2f             [32, 32, 1, True]             
  3                  -1  1     18560  ultralytics.nn.modules.conv.Conv             [32, 64, 3, 2]                
  4                  -1  2     49664  ultralytics.nn.modules.block.C2f             [64, 64, 2, True]             
  5                  -1  1     73984  ultralytics.nn.modules.conv.Conv             [64, 128, 3, 2]               
  6                  -1  2    197632  ultralytics.nn.modules.block.C2f             [128, 128, 2, True]           
  7                  -1  1    295424  ultralytics.nn.modules.conv.Conv             [128, 256, 3, 2]              
  8                  -1  1    460288  ultralytics.nn.modules.block.C2f             [256, 256, 1, True]           
  9                  -1  1    164608  ultralytics.nn.modules.block.SPPF            [256, 256, 5]                 
 10                  -1  1         0  torch.nn.modules.upsampling.Upsample         [None, 2, 'nearest']          
 11             [-1, 6]  1         0  ultralytics.nn.modules.conv.Concat           [1]                           
 12                  -1  1    148224  ultralytics.nn.modules.block.C2f             [384, 128, 1]                 
 13                  -1  1         0  torch.nn.modules.upsampling.Upsample         [None, 2, 'nearest']          
 14             [-1, 4]  1         0  ultralytics.nn.modules.conv.Concat           [1]                           
 15                  -1  1     37248  ultralytics.nn.modules.block.C2f             [192, 64, 1]                  
 16                  -1  1     36992  ultralytics.nn.modules.conv.Conv             [64, 64, 3, 2]                
 17            [-1, 12]  1         0  ultralytics.nn.modules.conv.Concat           [1]                           
 18                  -1  1    123648  ultralytics.nn.modules.block.C2f             [192, 128, 1]                 
 19                  -1  1    147712  ultralytics.nn.modules.conv.Conv             [128, 128, 3, 2]              
 20             [-1, 9]  1         0  ultralytics.nn.modules.conv.Concat           [1]                           
 21                  -1  1    493056  ultralytics.nn.modules.block.C2f             [384, 256, 1]                 
 22        [15, 18, 21]  1    751702  ultralytics.nn.modules.head.Detect           [2, [64, 128, 256]]           
Model summary: 225 layers, 3,011,238 parameters, 3,011,222 gradients, 8.2 GFLOPs

Transferred 319/355 items from pretrained weights
TensorBoard: Start with 'tensorboard --logdir runs/detect/train', view at http://localhost:6006/
Freezing layer 'model.22.dfl.conv.weight'
AMP: running Automatic Mixed Precision (AMP) checks...
Downloading https://github.com/ultralytics/assets/releases/download/v8.3.0/yolo11n.pt to 'yolo11n.pt'...
100%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| 5.35M/5.35M [00:00<00:00, 171MB/s]
AMP: checks passed βœ…
train: Scanning /kaggle/working/smokeandfire-2/train/labels... 8243 images, 11 b
train: New cache created: /kaggle/working/smokeandfire-2/train/labels.cache
WARNING ⚠️ Box and segment counts should be equal, but got len(segments) = 12, len(boxes) = 16365. To resolve this only boxes will be used and all segments will be removed. To avoid this please supply either a detect or segment dataset, not a detect-segment mixed dataset.
/opt/conda/lib/python3.10/site-packages/albumentations/__init__.py:24: UserWarning: A new version of Albumentations is available: 2.0.3 (you have 1.4.21). Upgrade using: pip install -U albumentations. To disable automatic update checks, set the environment variable NO_ALBUMENTATIONS_UPDATE to 1.
  check_for_updates()
albumentations: Blur(p=0.01, blur_limit=(3, 7)), MedianBlur(p=0.01, blur_limit=(3, 7)), ToGray(p=0.01, num_output_channels=3, method='weighted_average'), CLAHE(p=0.01, clip_limit=(1.0, 4.0), tile_grid_size=(8, 8))
/opt/conda/lib/python3.10/multiprocessing/popen_fork.py:66: RuntimeWarning: os.fork() was called. os.fork() is incompatible with multithreaded code, and JAX is multithreaded, so this will likely lead to a deadlock.
  self.pid = os.fork()
val: Scanning /kaggle/working/smokeandfire-2/valid/labels... 1062 images, 3 back
val: New cache created: /kaggle/working/smokeandfire-2/valid/labels.cache
/opt/conda/lib/python3.10/multiprocessing/popen_fork.py:66: RuntimeWarning: os.fork() was called. os.fork() is incompatible with multithreaded code, and JAX is multithreaded, so this will likely lead to a deadlock.
  self.pid = os.fork()
Plotting labels to runs/detect/train/labels.jpg... 
optimizer: 'optimizer=auto' found, ignoring 'lr0=0.01' and 'momentum=0.937' and determining best 'optimizer', 'lr0' and 'momentum' automatically... 
optimizer: SGD(lr=0.01, momentum=0.9) with parameter groups 57 weight(decay=0.0), 64 weight(decay=0.0005), 63 bias(decay=0.0)
TensorBoard: model graph visualization added βœ…
Image sizes 640 train, 640 val
Using 4 dataloader workers
Logging results to runs/detect/train
Starting training for 80 epochs...

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       1/80      4.28G       1.46      2.732      1.525        111        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.643      0.594      0.623      0.448

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       2/80      4.04G      1.351      1.809      1.427         68        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.786      0.643      0.693      0.481

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       3/80      4.04G      1.395      1.662      1.462         42        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.68      0.645       0.65      0.438

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       4/80      4.04G      1.443      1.629      1.516         67        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.773      0.648      0.703      0.507

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       5/80      4.04G      1.391      1.488      1.474         69        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.832      0.706      0.757      0.562

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       6/80      4.04G       1.37       1.43      1.456         65        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.824      0.759      0.772      0.556

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       7/80      4.04G       1.32      1.352      1.423         66        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.837       0.76      0.795       0.58

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       8/80      4.04G      1.305      1.314      1.413         54        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.848      0.791      0.806      0.598

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       9/80      4.13G      1.273      1.264      1.398         49        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.834      0.815       0.82      0.616

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      10/80      4.04G      1.276      1.265      1.403         79        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.847      0.778      0.811      0.614

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      11/80      4.04G      1.234      1.212      1.376         59        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.843       0.79      0.811      0.619

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      12/80      4.04G      1.231      1.203      1.376         81        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.859       0.82      0.835      0.642

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      13/80      4.04G      1.228      1.182      1.371         57        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.852      0.796      0.815      0.633

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      14/80      4.03G      1.209      1.163      1.361         66        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.847       0.83       0.84      0.643

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      15/80      4.03G      1.193       1.14      1.357         78        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.856      0.817       0.82      0.632

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      16/80      4.04G      1.178       1.11      1.345         68        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.868      0.821      0.841      0.648

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      17/80      4.04G      1.186      1.121      1.344         68        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.862      0.832      0.847      0.659

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      18/80      4.04G      1.157      1.088      1.323         75        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.858      0.814      0.837      0.654

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      19/80      4.04G      1.166      1.096      1.331         53        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.888      0.822      0.851      0.666

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      20/80      4.04G      1.149      1.065      1.325         82        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.858      0.833      0.848      0.668

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      21/80      4.04G      1.148      1.064      1.324         62        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.863      0.828      0.841      0.664

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      22/80      4.04G      1.147      1.049      1.315         79        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.877      0.836      0.854      0.671

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      23/80      4.04G      1.124      1.029      1.307         71        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.887      0.821      0.848       0.67

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      24/80      4.04G      1.125      1.027      1.299         75        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.874      0.831      0.853      0.668

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      25/80      4.03G      1.112       1.01       1.29         51        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.872      0.839      0.848      0.673

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      26/80      4.04G      1.116      1.014      1.295         81        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.869      0.836      0.852      0.677

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      27/80      4.03G      1.105     0.9947      1.291         73        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.891      0.836      0.851      0.679

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      28/80      4.03G      1.098     0.9788      1.283         58        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.895      0.839      0.868      0.684

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      29/80      4.03G      1.099     0.9862       1.29         68        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.883      0.843      0.857      0.681

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      30/80      4.04G      1.097     0.9711       1.28         40        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.889      0.837      0.861      0.686

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      31/80      4.03G      1.088     0.9652      1.276         47        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.878      0.844      0.862      0.691

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      32/80      4.03G      1.072     0.9448      1.266         68        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.886      0.833      0.857      0.684

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      33/80      4.03G      1.078     0.9493      1.263         77        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.884      0.846      0.863      0.686

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      34/80      4.04G      1.059     0.9343      1.257         47        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.892      0.843       0.86      0.688

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      35/80      4.03G      1.064     0.9361      1.264         54        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.891      0.844      0.862      0.688

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      36/80      4.04G      1.073     0.9309      1.262         70        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.888      0.844      0.862      0.686

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      37/80      4.04G      1.062     0.9132      1.257         41        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.887      0.854      0.868      0.694

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      38/80      4.03G      1.041     0.9034      1.244         62        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.891      0.846      0.861      0.693

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      39/80      4.04G      1.042     0.8871      1.243         56        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.897      0.854      0.866      0.696

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      40/80      4.03G      1.035     0.8803      1.239         77        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.895      0.842      0.863      0.693

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      41/80      4.04G      1.036     0.8864      1.238         54        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.888      0.856      0.864      0.694

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      42/80      4.04G      1.031     0.8757      1.235         61        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.894      0.855      0.867      0.696

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      43/80      4.03G      1.032     0.8717      1.238         56        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.884      0.862       0.87      0.704

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      44/80      4.03G      1.025     0.8757      1.234         65        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.89       0.86      0.866      0.701

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      45/80      4.03G      1.018     0.8574      1.232         61        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.893      0.855      0.865      0.698

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      46/80      4.04G      1.014     0.8478      1.222         74        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.898      0.849      0.863        0.7

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      47/80      4.04G      1.001     0.8449      1.217         55        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.894      0.853      0.862      0.701

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      48/80      4.03G      1.022     0.8509       1.23         63        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.893      0.853      0.868      0.703

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      49/80      4.03G      1.001     0.8292      1.214         74        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.894       0.85      0.866      0.701

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      50/80      4.03G     0.9953     0.8194      1.213         70        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.901      0.853      0.864      0.702

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      51/80      4.03G     0.9899     0.8199      1.204         69        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.892      0.856      0.866      0.704

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      52/80      4.03G     0.9847      0.811      1.204         71        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.894      0.857      0.869      0.707

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      53/80      4.03G     0.9856     0.8148      1.204         56        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.899      0.854      0.867      0.707

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      54/80      4.03G     0.9765     0.7975      1.198         79        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.895      0.854      0.871      0.709

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      55/80      4.03G      0.972     0.7906      1.196         59        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.904      0.855      0.872      0.707

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      56/80      4.03G     0.9653     0.7835      1.193         76        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.899      0.857       0.87      0.709

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      57/80      4.03G     0.9713     0.7852      1.191         63        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.903      0.854       0.87      0.709

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      58/80      4.03G     0.9614     0.7743      1.188         98        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.899      0.863      0.873      0.713

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      59/80      4.03G     0.9609     0.7649       1.19        120        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.904      0.855      0.874      0.709

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      60/80      4.03G     0.9524     0.7774      1.187         73        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.905      0.857      0.869      0.711

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      61/80      4.03G     0.9534     0.7619      1.185         63        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.898      0.856      0.868      0.707

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      62/80      4.03G     0.9391     0.7483      1.172         63        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.904       0.85      0.868      0.707

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      63/80      4.04G     0.9416     0.7508      1.178         73        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.899      0.858      0.869      0.708

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      64/80      4.04G     0.9248      0.735      1.167         62        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081        0.9      0.861      0.872       0.71

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      65/80      4.03G     0.9385     0.7398      1.172         97        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.901       0.86      0.869       0.71

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      66/80      4.03G     0.9379      0.737      1.173         56        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081        0.9      0.858       0.87      0.708

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      67/80      4.03G     0.9173     0.7124       1.16         79        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.906      0.859      0.871       0.71

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      68/80      4.03G     0.9239     0.7183      1.165         78        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.906      0.864      0.872      0.712

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      69/80      4.03G     0.9043     0.7065      1.153         68        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.904      0.856      0.873      0.713

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      70/80      4.03G      0.908     0.7109      1.155         75        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.902      0.857      0.871       0.71
Closing dataloader mosaic
albumentations: Blur(p=0.01, blur_limit=(3, 7)), MedianBlur(p=0.01, blur_limit=(3, 7)), ToGray(p=0.01, num_output_channels=3, method='weighted_average'), CLAHE(p=0.01, clip_limit=(1.0, 4.0), tile_grid_size=(8, 8))
/opt/conda/lib/python3.10/multiprocessing/popen_fork.py:66: RuntimeWarning: os.fork() was called. os.fork() is incompatible with multithreaded code, and JAX is multithreaded, so this will likely lead to a deadlock.
  self.pid = os.fork()

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      71/80      4.27G     0.9224     0.6481      1.167         44        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.908      0.852      0.874      0.712

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      72/80      4.03G     0.9097     0.6335      1.159         34        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.901      0.861      0.873      0.714

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      73/80      4.03G     0.8956     0.6201      1.145         37        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.908      0.854      0.872      0.714

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      74/80      4.03G     0.8915     0.6142      1.146         39        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.902      0.855      0.871      0.714

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      75/80      4.03G     0.8798     0.6015       1.14         36        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081        0.9      0.858      0.871      0.714

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      76/80      4.04G     0.8763     0.5909      1.135         32        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081        0.9      0.857      0.871      0.715

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      77/80      4.04G     0.8724     0.5878      1.134         49        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081        0.9      0.856       0.87      0.714

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      78/80      4.03G     0.8691     0.5789       1.13         43        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.902      0.856       0.87      0.713

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      79/80      4.03G     0.8659     0.5741      1.128         39        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.897       0.86       0.87      0.714

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      80/80      4.03G      0.852     0.5651      1.121         49        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081        0.9      0.857       0.87      0.714

80 epochs completed in 1.898 hours.
Optimizer stripped from runs/detect/train/weights/last.pt, 6.3MB
Optimizer stripped from runs/detect/train/weights/best.pt, 6.3MB

Validating runs/detect/train/weights/best.pt...
Ultralytics 8.3.70 πŸš€ Python-3.10.14 torch-2.4.0 CUDA:0 (Tesla P100-PCIE-16GB, 16269MiB)
Model summary (fused): 168 layers, 3,006,038 parameters, 0 gradients, 8.1 GFLOPs
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.896      0.862       0.87      0.713
                  Fire        859       1320      0.916       0.94      0.932      0.773
                 Smoke        559        761      0.876      0.783      0.808      0.652
Speed: 0.1ms preprocess, 4.8ms inference, 0.0ms loss, 0.8ms postprocess per image
Results saved to runs/detect/train
πŸ’‘ Learn more at https://docs.ultralytics.com/modes/train

yolo V8-SmallΒΆ

InΒ [Β ]:
!yolo train model=yolov8s.pt data='/kaggle/working/smokeandfire-2/data.yaml' epochs=80 imgsz=640 batch=32  augment=True
Downloading https://github.com/ultralytics/assets/releases/download/v8.3.0/yolov8s.pt to 'yolov8s.pt'...
100%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| 21.5M/21.5M [00:00<00:00, 186MB/s]
Ultralytics 8.3.27 πŸš€ Python-3.10.14 torch-2.4.0 CUDA:0 (Tesla P100-PCIE-16GB, 16269MiB)
engine/trainer: task=detect, mode=train, model=yolov8s.pt, data=/kaggle/working/smokeandfire-2/data.yaml, epochs=80, time=None, patience=100, batch=32, imgsz=640, save=True, save_period=-1, cache=False, device=None, workers=8, project=None, name=train, exist_ok=False, pretrained=True, optimizer=auto, verbose=True, seed=0, deterministic=True, single_cls=False, rect=False, cos_lr=False, close_mosaic=10, resume=False, amp=True, fraction=1.0, profile=False, freeze=None, multi_scale=False, overlap_mask=True, mask_ratio=4, dropout=0.0, val=True, split=val, save_json=False, save_hybrid=False, conf=None, iou=0.7, max_det=300, half=False, dnn=False, plots=True, source=None, vid_stride=1, stream_buffer=False, visualize=False, augment=True, agnostic_nms=False, classes=None, retina_masks=False, embed=None, show=False, save_frames=False, save_txt=False, save_conf=False, save_crop=False, show_labels=True, show_conf=True, show_boxes=True, line_width=None, format=torchscript, keras=False, optimize=False, int8=False, dynamic=False, simplify=True, opset=None, workspace=4, nms=False, lr0=0.01, lrf=0.01, momentum=0.937, weight_decay=0.0005, warmup_epochs=3.0, warmup_momentum=0.8, warmup_bias_lr=0.1, box=7.5, cls=0.5, dfl=1.5, pose=12.0, kobj=1.0, label_smoothing=0.0, nbs=64, hsv_h=0.015, hsv_s=0.7, hsv_v=0.4, degrees=0.0, translate=0.1, scale=0.5, shear=0.0, perspective=0.0, flipud=0.0, fliplr=0.5, bgr=0.0, mosaic=1.0, mixup=0.0, copy_paste=0.0, copy_paste_mode=flip, auto_augment=randaugment, erasing=0.4, crop_fraction=1.0, cfg=None, tracker=botsort.yaml, save_dir=runs/detect/train
Downloading https://ultralytics.com/assets/Arial.ttf to '/root/.config/Ultralytics/Arial.ttf'...
100%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| 755k/755k [00:00<00:00, 22.1MB/s]
Overriding model.yaml nc=80 with nc=2

                   from  n    params  module                                       arguments                     
  0                  -1  1       928  ultralytics.nn.modules.conv.Conv             [3, 32, 3, 2]                 
  1                  -1  1     18560  ultralytics.nn.modules.conv.Conv             [32, 64, 3, 2]                
  2                  -1  1     29056  ultralytics.nn.modules.block.C2f             [64, 64, 1, True]             
  3                  -1  1     73984  ultralytics.nn.modules.conv.Conv             [64, 128, 3, 2]               
  4                  -1  2    197632  ultralytics.nn.modules.block.C2f             [128, 128, 2, True]           
  5                  -1  1    295424  ultralytics.nn.modules.conv.Conv             [128, 256, 3, 2]              
  6                  -1  2    788480  ultralytics.nn.modules.block.C2f             [256, 256, 2, True]           
  7                  -1  1   1180672  ultralytics.nn.modules.conv.Conv             [256, 512, 3, 2]              
  8                  -1  1   1838080  ultralytics.nn.modules.block.C2f             [512, 512, 1, True]           
  9                  -1  1    656896  ultralytics.nn.modules.block.SPPF            [512, 512, 5]                 
 10                  -1  1         0  torch.nn.modules.upsampling.Upsample         [None, 2, 'nearest']          
 11             [-1, 6]  1         0  ultralytics.nn.modules.conv.Concat           [1]                           
 12                  -1  1    591360  ultralytics.nn.modules.block.C2f             [768, 256, 1]                 
 13                  -1  1         0  torch.nn.modules.upsampling.Upsample         [None, 2, 'nearest']          
 14             [-1, 4]  1         0  ultralytics.nn.modules.conv.Concat           [1]                           
 15                  -1  1    148224  ultralytics.nn.modules.block.C2f             [384, 128, 1]                 
 16                  -1  1    147712  ultralytics.nn.modules.conv.Conv             [128, 128, 3, 2]              
 17            [-1, 12]  1         0  ultralytics.nn.modules.conv.Concat           [1]                           
 18                  -1  1    493056  ultralytics.nn.modules.block.C2f             [384, 256, 1]                 
 19                  -1  1    590336  ultralytics.nn.modules.conv.Conv             [256, 256, 3, 2]              
 20             [-1, 9]  1         0  ultralytics.nn.modules.conv.Concat           [1]                           
 21                  -1  1   1969152  ultralytics.nn.modules.block.C2f             [768, 512, 1]                 
 22        [15, 18, 21]  1   2116822  ultralytics.nn.modules.head.Detect           [2, [128, 256, 512]]          
Model summary: 225 layers, 11,136,374 parameters, 11,136,358 gradients, 28.6 GFLOPs

Transferred 349/355 items from pretrained weights
TensorBoard: Start with 'tensorboard --logdir runs/detect/train', view at http://localhost:6006/
Freezing layer 'model.22.dfl.conv.weight'
AMP: running Automatic Mixed Precision (AMP) checks...
Downloading https://github.com/ultralytics/assets/releases/download/v8.3.0/yolo11n.pt to 'yolo11n.pt'...
100%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| 5.35M/5.35M [00:00<00:00, 91.4MB/s]
AMP: checks passed βœ…
train: Scanning /kaggle/working/smokeandfire-2/train/labels... 8243 images, 11 b
train: New cache created: /kaggle/working/smokeandfire-2/train/labels.cache
WARNING ⚠️ Box and segment counts should be equal, but got len(segments) = 12, len(boxes) = 16365. To resolve this only boxes will be used and all segments will be removed. To avoid this please supply either a detect or segment dataset, not a detect-segment mixed dataset.
/opt/conda/lib/python3.10/site-packages/albumentations/__init__.py:13: UserWarning: A new version of Albumentations is available: 1.4.21 (you have 1.4.17). Upgrade using: pip install -U albumentations. To disable automatic update checks, set the environment variable NO_ALBUMENTATIONS_UPDATE to 1.
  check_for_updates()
albumentations: Blur(p=0.01, blur_limit=(3, 7)), MedianBlur(p=0.01, blur_limit=(3, 7)), ToGray(p=0.01, num_output_channels=3, method='weighted_average'), CLAHE(p=0.01, clip_limit=(1, 4.0), tile_grid_size=(8, 8))
/opt/conda/lib/python3.10/multiprocessing/popen_fork.py:66: RuntimeWarning: os.fork() was called. os.fork() is incompatible with multithreaded code, and JAX is multithreaded, so this will likely lead to a deadlock.
  self.pid = os.fork()
val: Scanning /kaggle/working/smokeandfire-2/valid/labels... 1062 images, 3 back
val: New cache created: /kaggle/working/smokeandfire-2/valid/labels.cache
Plotting labels to runs/detect/train/labels.jpg... 
optimizer: 'optimizer=auto' found, ignoring 'lr0=0.01' and 'momentum=0.937' and determining best 'optimizer', 'lr0' and 'momentum' automatically... 
optimizer: SGD(lr=0.01, momentum=0.9) with parameter groups 57 weight(decay=0.0), 64 weight(decay=0.0005), 63 bias(decay=0.0)
TensorBoard: model graph visualization added βœ…
Image sizes 640 train, 640 val
Using 4 dataloader workers
Logging results to runs/detect/train
Starting training for 80 epochs...

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       1/80      8.06G      1.457      2.109      1.552         64        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.835      0.704      0.742       0.55

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       2/80      8.22G      1.255      1.287      1.389         67        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.804      0.746      0.779      0.581

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       3/80      8.28G      1.324      1.345      1.428         66        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.661      0.556      0.565      0.398

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       4/80      8.31G      1.384      1.435      1.471         70        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.735      0.629      0.682      0.502

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       5/80      8.31G      1.351      1.367      1.447         72        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.821      0.681      0.726      0.543

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       6/80       8.3G      1.304      1.301      1.434         65        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.829      0.757      0.785       0.59

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       7/80      8.29G      1.267      1.234      1.409         58        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.816      0.791      0.816       0.62

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       8/80      8.38G      1.252      1.204      1.403         77        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.832      0.754      0.778      0.599

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       9/80      8.37G      1.225      1.159      1.379         86        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.863      0.807      0.829      0.635

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      10/80      8.37G      1.229      1.166      1.381         50        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.834      0.776      0.804       0.62

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      11/80      8.29G      1.197       1.12      1.363         54        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.856      0.822      0.837      0.643

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      12/80      8.37G      1.179      1.097      1.352         64        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.83      0.806      0.814       0.63

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      13/80      8.37G      1.177      1.084      1.352         82        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.86      0.825       0.83      0.648

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      14/80      8.38G      1.159      1.055      1.335         63        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.872      0.823      0.832       0.65

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      15/80      8.37G      1.148       1.04      1.329         64        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.871      0.828      0.838      0.656

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      16/80      8.37G      1.123     0.9982      1.309         70        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.88      0.838      0.851      0.668

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      17/80      8.38G      1.117      1.002      1.317         62        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.882      0.814      0.853      0.669

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      18/80      8.29G      1.106     0.9717      1.296         57        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.877       0.84      0.841      0.664

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      19/80      8.29G      1.106     0.9747        1.3         46        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.873      0.838       0.85      0.676

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      20/80      8.29G      1.085     0.9517      1.287         57        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.863      0.838      0.859      0.676

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      21/80      8.37G      1.086     0.9434      1.281         56        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.879       0.84      0.856      0.679

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      22/80      8.37G      1.077     0.9353      1.278         48        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.884      0.832       0.86      0.681

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      23/80      8.37G      1.078     0.9254      1.273         57        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.898      0.843      0.863      0.687

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      24/80      8.37G      1.069     0.9217      1.273         79        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.891      0.843      0.858      0.685

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      25/80      8.37G      1.062     0.9139      1.268         63        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.885      0.844      0.867      0.691

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      26/80      8.37G       1.05     0.8975      1.258         71        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.881      0.844      0.864      0.688

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      27/80       8.3G      1.034       0.88       1.25        104        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.887      0.857      0.864      0.688

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      28/80       8.3G      1.038     0.8747      1.255         46        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.882      0.858      0.874      0.701

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      29/80      8.37G      1.023     0.8579      1.246         67        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.87      0.861      0.864      0.696

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      30/80      8.37G      1.022     0.8496      1.242         73        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.888      0.849      0.866      0.694

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      31/80      8.37G      1.015     0.8321      1.239         64        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.887      0.849       0.86      0.699

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      32/80      8.37G     0.9935     0.8153      1.218         80        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.892      0.851      0.869      0.704

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      33/80      8.37G      1.003     0.8232      1.226         74        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.906      0.848       0.87      0.706

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      34/80      8.37G      0.996     0.8132      1.228         55        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.888      0.855      0.866        0.7

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      35/80      8.37G     0.9954     0.8055      1.225         59        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.888      0.857      0.867        0.7

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      36/80      8.37G      0.987     0.7936      1.213         60        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.893      0.849      0.867      0.703

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      37/80      8.37G     0.9708       0.78      1.205         58        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.897      0.858      0.873      0.709

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      38/80       8.3G     0.9749     0.7767      1.199         71        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.898       0.86      0.873      0.706

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      39/80      8.28G     0.9713     0.7719      1.198         55        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.892      0.857      0.869      0.704

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      40/80       8.3G     0.9569     0.7549      1.193         63        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.901      0.858       0.87      0.705

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      41/80      8.29G     0.9433     0.7394      1.185         89        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.902      0.859      0.872      0.711

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      43/80      8.37G     0.9451     0.7332      1.183         41        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.888       0.86      0.871      0.709

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      46/80      8.37G     0.9217     0.7077      1.166         82        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.897       0.86      0.875      0.713

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      47/80       8.3G     0.9227     0.6978      1.159         60        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.892      0.857      0.879      0.714

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      48/80      8.29G     0.9125     0.6868      1.166         59        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.895      0.859      0.872      0.709

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      49/80      8.29G     0.9072     0.6779      1.153         41        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.896      0.862      0.877      0.716

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      50/80      8.28G     0.9092     0.6773      1.159         48        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.896      0.862      0.874      0.715

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      51/80      8.38G     0.8942     0.6712      1.147         74        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.901      0.857      0.873      0.711

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      52/80      8.29G     0.8948      0.668      1.144         63        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.901      0.858      0.876      0.714

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      53/80      8.29G     0.8872     0.6579      1.144         67        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.894      0.866      0.875      0.712

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      54/80      8.29G     0.8826     0.6462      1.141         68        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.898      0.866      0.878      0.717

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      55/80      8.29G     0.8757     0.6416      1.134         53        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.898       0.86      0.876      0.717

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      56/80       8.3G     0.8757     0.6442      1.137         61        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.889      0.854      0.876      0.718

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      57/80      8.28G     0.8671     0.6283      1.126         87        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.898      0.856      0.875      0.725

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      58/80      8.28G     0.8548     0.6194       1.12         52        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.896      0.858      0.877      0.721

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      59/80      8.37G     0.8509     0.6142      1.115         49        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081        0.9      0.855      0.874      0.716

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      60/80      8.29G     0.8487     0.6082      1.119         71        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.89      0.853      0.873      0.718

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      61/80      8.29G     0.8438     0.5988      1.115         83        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.901       0.85      0.871      0.715

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      62/80      8.29G     0.8404     0.5922      1.116         60        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.896      0.859      0.873      0.718

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      63/80      8.29G      0.827     0.5874      1.109         59        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.895      0.861      0.873      0.719

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      64/80      8.37G     0.8218     0.5798      1.103         55        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.89      0.867      0.871      0.719

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      65/80      8.37G       0.83     0.5832      1.105         79        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.893      0.862      0.874      0.719

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      66/80      8.37G     0.8059     0.5597      1.089         74        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.896      0.863      0.875      0.721

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      67/80      8.37G     0.8043     0.5658      1.092         96        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.893      0.865      0.872       0.72

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      68/80      8.37G     0.7967     0.5554       1.09         85        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.886      0.866      0.874      0.721

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      69/80      8.37G     0.7953     0.5495      1.088         71        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.89      0.861      0.874      0.722

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      70/80      8.37G      0.796     0.5458      1.081         56        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.891      0.863       0.87      0.718
Closing dataloader mosaic
albumentations: Blur(p=0.01, blur_limit=(3, 7)), MedianBlur(p=0.01, blur_limit=(3, 7)), ToGray(p=0.01, num_output_channels=3, method='weighted_average'), CLAHE(p=0.01, clip_limit=(1, 4.0), tile_grid_size=(8, 8))
/opt/conda/lib/python3.10/multiprocessing/popen_fork.py:66: RuntimeWarning: os.fork() was called. os.fork() is incompatible with multithreaded code, and JAX is multithreaded, so this will likely lead to a deadlock.
  self.pid = os.fork()

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      71/80      8.37G     0.7757     0.4712      1.066         46        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.896      0.856      0.867      0.717

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      72/80      8.37G     0.7661     0.4539      1.054         34        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.898      0.857      0.868      0.715

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      73/80      8.37G     0.7474     0.4406      1.044         35        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.894      0.856      0.868      0.718

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      74/80      8.37G     0.7435     0.4356      1.043         39        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.89       0.86      0.871       0.72

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      75/80      8.37G     0.7309     0.4248      1.037         37        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.886      0.862      0.871      0.719

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      76/80      8.37G     0.7278     0.4191      1.033         32        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.888       0.86      0.871      0.719

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      77/80      8.37G     0.7142     0.4116      1.026         49        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.892      0.859      0.872       0.72

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      78/80      8.37G     0.7086     0.4014      1.025         42        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.893      0.857       0.87      0.721

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      79/80      8.37G      0.701     0.3992      1.019         37        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.891      0.854      0.869      0.721

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      80/80      8.37G     0.6978     0.3968      1.019         46        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.889      0.854      0.869      0.721

80 epochs completed in 3.195 hours.
Optimizer stripped from runs/detect/train/weights/last.pt, 22.5MB
Optimizer stripped from runs/detect/train/weights/best.pt, 22.5MB

Validating runs/detect/train/weights/best.pt...
Ultralytics 8.3.27 πŸš€ Python-3.10.14 torch-2.4.0 CUDA:0 (Tesla P100-PCIE-16GB, 16269MiB)
Model summary (fused): 168 layers, 11,126,358 parameters, 0 gradients, 28.4 GFLOPs
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.878      0.867      0.874      0.718
                  Fire        859       1320      0.903      0.943      0.936      0.783
                 Smoke        559        761      0.853      0.792      0.812      0.653
Speed: 0.1ms preprocess, 10.0ms inference, 0.0ms loss, 0.7ms postprocess per image
Results saved to runs/detect/train
πŸ’‘ Learn more at https://docs.ultralytics.com/modes/train

using yolo8s cuz of unstability of yolo8m

results of yolov8sΒΆ

InΒ [Β ]:
import matplotlib.pyplot as plt
import matplotlib.image as mpimg

img = mpimg.imread('/kaggle/working/runs/detect/train/results.png')
imgplot = plt.imshow(img)
plt.show()
No description has been provided for this image
InΒ [Β ]:
img = mpimg.imread('/kaggle/working/runs/detect/train/confusion_matrix_normalized.png')
imgplot = plt.imshow(img)
plt.show()
No description has been provided for this image
InΒ [Β ]:
img = mpimg.imread('/kaggle/working/runs/detect/train/P_curve.png')
imgplot = plt.imshow(img)
plt.show()
No description has been provided for this image
InΒ [Β ]:
img = mpimg.imread('/kaggle/working/runs/detect/train/val_batch0_pred.jpg')
imgplot = plt.imshow(img)
plt.show()
No description has been provided for this image
InΒ [Β ]:
!yolo task=detect mode=predict model="/kaggle/working/runs/detect/train/weights/best.pt" device=0 source="/kaggle/working/smokeandfire-2/test/images" save=True
InΒ [Β ]:
from glob import glob
from PIL import Image
import numpy as np

img_path = glob('/kaggle/working/runs/detect/predict/*.jpg')
img_path = np.random.choice(img_path, 10)

for image_path in img_path:
    plt.imshow(Image.open(image_path))
    plt.axis("off")
    plt.show()
    print("\n")
No description has been provided for this image

No description has been provided for this image

No description has been provided for this image

No description has been provided for this image

No description has been provided for this image

No description has been provided for this image

No description has been provided for this image

No description has been provided for this image

No description has been provided for this image

No description has been provided for this image

InΒ [Β ]:
!yolo predict model="/kaggle/working/runs/detect/train/weights/best.pt", source="/kaggle/input/fireee/fire.109.jpg"
WARNING ⚠️ argument 'model=/kaggle/working/runs/detect/train/weights/best.pt,' does not require trailing comma ',', updating to 'model=/kaggle/working/runs/detect/train/weights/best.pt'.
Ultralytics 8.3.27 πŸš€ Python-3.10.14 torch-2.4.0 CUDA:0 (Tesla P100-PCIE-16GB, 16269MiB)
Model summary (fused): 168 layers, 11,126,358 parameters, 0 gradients, 28.4 GFLOPs

image 1/1 /kaggle/input/fireee/fire.109.jpg: 384x640 3 Fires, 54.8ms
Speed: 4.4ms preprocess, 54.8ms inference, 165.3ms postprocess per image at shape (1, 3, 384, 640)
Results saved to runs/detect/predict2
πŸ’‘ Learn more at https://docs.ultralytics.com/modes/predict

test on new imagesΒΆ

InΒ [Β ]:
import cv2
import matplotlib.pyplot as plt

# Path to the output image
output_image_path = "/kaggle/working/runs/detect/predict2/fire.109.jpg"  

# Load the output image
output_image = cv2.imread(output_image_path)
output_image = cv2.cvtColor(output_image, cv2.COLOR_BGR2RGB) 

# Display the output image
plt.figure(figsize=(8, 8))
plt.imshow(output_image)
plt.title('Detected Image - fire.109.jpg')
plt.axis('off')  # Hide axes
plt.show()
No description has been provided for this image
InΒ [Β ]:
!yolo predict model="/kaggle/working/runs/detect/train/weights/best.pt", source="/kaggle/input/smokee/17_jpg.rf.001aef48a2d04d48f389f096c8f3e478.jpg"
InΒ [Β ]:
output_image_path = "/kaggle/working/runs/detect/predict3/17_jpg.rf.001aef48a2d04d48f389f096c8f3e478.jpg"  

# Load the output image
output_image = cv2.imread(output_image_path)
output_image = cv2.cvtColor(output_image, cv2.COLOR_BGR2RGB)  

# Display the output image
plt.figure(figsize=(8, 8))
plt.imshow(output_image)
plt.title('Detected Image - fire.109.jpg')
plt.axis('off')  # Hide axes
plt.show()
No description has been provided for this image
InΒ [Β ]:
!yolo predict model="/kaggle/working/runs/detect/train/weights/best.pt", source="/kaggle/input/fire-and-smoke-detection-for-yolov8/train/images/0058_jpg.rf.629dad210eae7f57976d164974befbe2.jpg"
WARNING ⚠️ argument 'model=/kaggle/working/runs/detect/train/weights/best.pt,' does not require trailing comma ',', updating to 'model=/kaggle/working/runs/detect/train/weights/best.pt'.
Ultralytics 8.3.27 πŸš€ Python-3.10.14 torch-2.4.0 CUDA:0 (Tesla P100-PCIE-16GB, 16269MiB)
Model summary (fused): 168 layers, 11,126,358 parameters, 0 gradients, 28.4 GFLOPs

image 1/1 /kaggle/input/fire-and-smoke-detection-for-yolov8/train/images/0058_jpg.rf.629dad210eae7f57976d164974befbe2.jpg: 640x640 1 Fire, 1 Smoke, 8.5ms
Speed: 4.9ms preprocess, 8.5ms inference, 159.6ms postprocess per image at shape (1, 3, 640, 640)
Results saved to runs/detect/predict4
πŸ’‘ Learn more at https://docs.ultralytics.com/modes/predict
InΒ [Β ]:
output_image_path = "/kaggle/working/runs/detect/predict4/0058_jpg.rf.629dad210eae7f57976d164974befbe2.jpg"

# Load the output image
output_image = cv2.imread(output_image_path)
output_image = cv2.cvtColor(output_image, cv2.COLOR_BGR2RGB)

# Display the output image
plt.figure(figsize=(8, 8))
plt.imshow(output_image)
plt.title('Detected Image')
plt.axis('off')  # Hide axes
plt.show()
No description has been provided for this image

yoloV5ΒΆ

InΒ [Β ]:
!pip install roboflow

from roboflow import Roboflow
rf = Roboflow(api_key="GZBlBPlRdRvB6uR7BqaS")
project = rf.workspace("detection-e83li").project("smokeandfire")
version = project.version(2)
dataset = version.download("yolov5")
InΒ [Β ]:
!git clone https://github.com/ultralytics/yolov5.git
Cloning into 'yolov5'...
remote: Enumerating objects: 17022, done.
remote: Total 17022 (delta 0), reused 0 (delta 0), pack-reused 17022 (from 1)
Receiving objects: 100% (17022/17022), 15.62 MiB | 25.10 MiB/s, done.
Resolving deltas: 100% (11695/11695), done.
InΒ [Β ]:
%cd yolov5
/kaggle/working/yolov5
InΒ [Β ]:
!pip install -r requirements.txt
InΒ [Β ]:
%env WANDB_MODE=disabled
env: WANDB_MODE=disabled
InΒ [Β ]:
!python train.py --weights yolov5n.pt --data '/kaggle/working/yolov5/smokeandfire-2/data.yaml' --epochs 80 --imgsz 640 --batch-size 32
InΒ [Β ]:
import matplotlib.pyplot as plt
import matplotlib.image as mpimg
img = mpimg.imread('/kaggle/working/yolov5/runs/train/exp/confusion_matrix.png')
imgplot = plt.imshow(img)
plt.show()
No description has been provided for this image
InΒ [Β ]:
img = mpimg.imread('/kaggle/working/yolov5/runs/train/exp/P_curve.png')
imgplot = plt.imshow(img)
plt.show()
No description has been provided for this image
InΒ [Β ]:
import matplotlib.pyplot as plt
import matplotlib.image as mpimg

img = mpimg.imread('/kaggle/working/yolov5/runs/train/exp/results.png')
imgplot = plt.imshow(img)
plt.show()
No description has been provided for this image
InΒ [Β ]:
!python detect.py --weights /kaggle/working/yolov5/runs/train/exp/weights/best.pt --img 640 --conf 0.35 --source /kaggle/working/yolov5/smokeandfire-2/test/images
InΒ [Β ]:
# Running YOLOv5 prediction from the terminal
!python detect.py --weights /kaggle/working/yolov5/runs/train/exp/weights/best.pt --source /kaggle/input/fireee/fire.109.jpg --img 640 --conf 0.25
detect: weights=['/kaggle/working/yolov5/runs/train/exp/weights/best.pt'], source=/kaggle/input/fireee/fire.109.jpg, data=data/coco128.yaml, imgsz=[640, 640], conf_thres=0.25, iou_thres=0.45, max_det=1000, device=, view_img=False, save_txt=False, save_format=0, save_csv=False, save_conf=False, save_crop=False, nosave=False, classes=None, agnostic_nms=False, augment=False, visualize=False, update=False, project=runs/detect, name=exp, exist_ok=False, line_thickness=3, hide_labels=False, hide_conf=False, half=False, dnn=False, vid_stride=1
YOLOv5 πŸš€ v7.0-378-g2f74455a Python-3.10.14 torch-2.4.0 CUDA:0 (Tesla P100-PCIE-16GB, 16269MiB)

Fusing layers... 
Model summary: 157 layers, 1761871 parameters, 0 gradients, 4.1 GFLOPs
image 1/1 /kaggle/input/fireee/fire.109.jpg: 384x640 2 Fires, 27.7ms
Speed: 0.5ms pre-process, 27.7ms inference, 134.5ms NMS per image at shape (1, 3, 640, 640)
Results saved to runs/detect/exp3

Test on new imagesΒΆ

InΒ [Β ]:
import cv2
import matplotlib.pyplot as plt

# Path to the output image
output_image_path = "/kaggle/working/yolov5/runs/detect/exp3/fire.109.jpg" 

# Load the output image
output_image = cv2.imread(output_image_path)
output_image = cv2.cvtColor(output_image, cv2.COLOR_BGR2RGB) 

# Display the output image
plt.figure(figsize=(8, 8))
plt.imshow(output_image)
plt.title('Detected Image - fire.109.jpg')
plt.axis('off')  # Hide axes
plt.show()
No description has been provided for this image
InΒ [Β ]:
# Running YOLOv5 prediction from the terminal
!python detect.py --weights /kaggle/working/yolov5/runs/train/exp/weights/best.pt --source /kaggle/input/fire-and-smoke-detection-for-yolov8/train/images/0058_jpg.rf.629dad210eae7f57976d164974befbe2.jpg --img 640 --conf 0.25
detect: weights=['/kaggle/working/yolov5/runs/train/exp/weights/best.pt'], source=/kaggle/input/fire-and-smoke-detection-for-yolov8/train/images/0058_jpg.rf.629dad210eae7f57976d164974befbe2.jpg, data=data/coco128.yaml, imgsz=[640, 640], conf_thres=0.25, iou_thres=0.45, max_det=1000, device=, view_img=False, save_txt=False, save_format=0, save_csv=False, save_conf=False, save_crop=False, nosave=False, classes=None, agnostic_nms=False, augment=False, visualize=False, update=False, project=runs/detect, name=exp, exist_ok=False, line_thickness=3, hide_labels=False, hide_conf=False, half=False, dnn=False, vid_stride=1
YOLOv5 πŸš€ v7.0-378-g2f74455a Python-3.10.14 torch-2.4.0 CUDA:0 (Tesla P100-PCIE-16GB, 16269MiB)

Fusing layers... 
Model summary: 157 layers, 1761871 parameters, 0 gradients, 4.1 GFLOPs
image 1/1 /kaggle/input/fire-and-smoke-detection-for-yolov8/train/images/0058_jpg.rf.629dad210eae7f57976d164974befbe2.jpg: 640x640 5 Fires, 1 Smoke, 6.2ms
Speed: 0.6ms pre-process, 6.2ms inference, 133.8ms NMS per image at shape (1, 3, 640, 640)
Results saved to runs/detect/exp4
InΒ [Β ]:
output_image_path = "/kaggle/working/yolov5/runs/detect/exp4/0058_jpg.rf.629dad210eae7f57976d164974befbe2.jpg"  # Adjust if the file name is different

# Load the output image
output_image = cv2.imread(output_image_path)
output_image = cv2.cvtColor(output_image, cv2.COLOR_BGR2RGB)  
# Display the output image
plt.figure(figsize=(8, 8))
plt.imshow(output_image)
plt.title('Detected Image - fire.109.jpg')
plt.axis('off')  # Hide axes
plt.show()
No description has been provided for this image

YoloV7ΒΆ

InΒ [Β ]:
!pip install roboflow

from roboflow import Roboflow
rf = Roboflow(api_key="GZBlBPlRdRvB6uR7BqaS")
project = rf.workspace("detection-e83li").project("smokeandfire")
version = project.version(2)
dataset = version.download("yolov7")
InΒ [Β ]:
!git clone https://github.com/WongKinYiu/yolov7.git
%cd yolov7
Cloning into 'yolov7'...
remote: Enumerating objects: 1197, done.
remote: Total 1197 (delta 0), reused 0 (delta 0), pack-reused 1197 (from 1)
Receiving objects: 100% (1197/1197), 74.23 MiB | 38.22 MiB/s, done.
Resolving deltas: 100% (520/520), done.
/kaggle/working/yolov7
InΒ [Β ]:
!pip install -r requirements.txt
InΒ [Β ]:
%env WANDB_MODE=disabled
env: WANDB_MODE=disabled
InΒ [Β ]:
import torch
torch.cuda.empty_cache()
InΒ [Β ]:
!python train.py --weights yolov7.pt --data '/kaggle/working/yolov7/smokeandfire-2/data.yaml' --epochs 80 --img-size 512 --batch-size 32
/kaggle/working/yolov7/train.py:71: FutureWarning: You are using `torch.load` with `weights_only=False` (the current default value), which uses the default pickle module implicitly. It is possible to construct malicious pickle data which will execute arbitrary code during unpickling (See https://github.com/pytorch/pytorch/blob/main/SECURITY.md#untrusted-models for more details). In a future release, the default value for `weights_only` will be flipped to `True`. This limits the functions that could be executed during unpickling. Arbitrary objects will no longer be allowed to be loaded via this mode unless they are explicitly allowlisted by the user via `torch.serialization.add_safe_globals`. We recommend you start setting `weights_only=True` for any use case where you don't have full control of the loaded file. Please open an issue on GitHub for any issues related to this experimental feature.
  run_id = torch.load(weights, map_location=device).get('wandb_id') if weights.endswith('.pt') and os.path.isfile(weights) else None
/kaggle/working/yolov7/train.py:87: FutureWarning: You are using `torch.load` with `weights_only=False` (the current default value), which uses the default pickle module implicitly. It is possible to construct malicious pickle data which will execute arbitrary code during unpickling (See https://github.com/pytorch/pytorch/blob/main/SECURITY.md#untrusted-models for more details). In a future release, the default value for `weights_only` will be flipped to `True`. This limits the functions that could be executed during unpickling. Arbitrary objects will no longer be allowed to be loaded via this mode unless they are explicitly allowlisted by the user via `torch.serialization.add_safe_globals`. We recommend you start setting `weights_only=True` for any use case where you don't have full control of the loaded file. Please open an issue on GitHub for any issues related to this experimental feature.
  ckpt = torch.load(weights, map_location=device)  # load checkpoint
/opt/conda/lib/python3.10/site-packages/torch/functional.py:513: UserWarning: torch.meshgrid: in an upcoming release, it will be required to pass the indexing argument. (Triggered internally at /usr/local/src/pytorch/aten/src/ATen/native/TensorShape.cpp:3609.)
  return _VF.meshgrid(tensors, **kwargs)  # type: ignore[attr-defined]
/kaggle/working/yolov7/utils/datasets.py:392: FutureWarning: You are using `torch.load` with `weights_only=False` (the current default value), which uses the default pickle module implicitly. It is possible to construct malicious pickle data which will execute arbitrary code during unpickling (See https://github.com/pytorch/pytorch/blob/main/SECURITY.md#untrusted-models for more details). In a future release, the default value for `weights_only` will be flipped to `True`. This limits the functions that could be executed during unpickling. Arbitrary objects will no longer be allowed to be loaded via this mode unless they are explicitly allowlisted by the user via `torch.serialization.add_safe_globals`. We recommend you start setting `weights_only=True` for any use case where you don't have full control of the loaded file. Please open an issue on GitHub for any issues related to this experimental feature.
  cache, exists = torch.load(cache_path), True  # load
train: Scanning 'smokeandfire-2/train/labels.cache' images and labels... 8243 fo
/opt/conda/lib/python3.10/multiprocessing/popen_fork.py:66: RuntimeWarning: os.fork() was called. os.fork() is incompatible with multithreaded code, and JAX is multithreaded, so this will likely lead to a deadlock.
  self.pid = os.fork()
val: Scanning 'smokeandfire-2/valid/labels.cache' images and labels... 1062 foun

autoanchor: Analyzing anchors... anchors/target = 4.83, Best Possible Recall (BPR) = 0.9982
/kaggle/working/yolov7/train.py:299: FutureWarning: `torch.cuda.amp.GradScaler(args...)` is deprecated. Please use `torch.amp.GradScaler('cuda', args...)` instead.
  scaler = amp.GradScaler(enabled=cuda)
  0%|                                                   | 0/258 [00:00<?, ?it/s]/kaggle/working/yolov7/train.py:360: FutureWarning: `torch.cuda.amp.autocast(args...)` is deprecated. Please use `torch.amp.autocast('cuda', args...)` instead.
  with amp.autocast(enabled=cuda):
      0/79     4.76G   0.06082   0.01174   0.01107   0.08362        93       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.686       0.576       0.608       0.359
      1/79       16G   0.04721  0.009793  0.004424   0.06143        96       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.795       0.697       0.734       0.456
      2/79     16.5G   0.04521  0.009044  0.003642   0.05789       106       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.832       0.751       0.779       0.506
      3/79     16.4G   0.04303  0.008948  0.003376   0.05536       107       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.853       0.742       0.779       0.512
      4/79     16.4G   0.04178  0.008852  0.003097   0.05373        90       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.861       0.733       0.773       0.532
      5/79     16.2G    0.0394  0.008794  0.002656   0.05085       104       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.853       0.786       0.804       0.566
      6/79     16.2G    0.0379  0.008572  0.002412   0.04888        82       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.877       0.812       0.818       0.589
      7/79     16.2G    0.0364  0.008379  0.002274   0.04706       120       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.892       0.802       0.825       0.579
      8/79     16.2G   0.03558  0.008295  0.002127     0.046        85       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.873       0.798       0.813       0.589
      9/79     16.2G   0.03499  0.008348  0.001946   0.04528        97       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.881       0.817       0.823         0.6
     10/79     16.2G    0.0346  0.008206  0.001891    0.0447        95       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081        0.89       0.821       0.827        0.61
     11/79     16.2G   0.03381  0.008055   0.00184   0.04371       120       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.891       0.813       0.836       0.618
     12/79     16.2G   0.03386  0.008203  0.001912   0.04397        98       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081        0.88       0.816       0.811       0.612
     13/79     16.6G   0.03323  0.008034  0.001781   0.04304       119       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.894       0.829       0.842       0.628
     14/79     16.6G   0.03283  0.007888  0.001682    0.0424       125       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081        0.88       0.837       0.838       0.615
     15/79     16.6G   0.03255  0.007959  0.001786   0.04229       106       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.894        0.84       0.839       0.637
     16/79     16.6G   0.03191   0.00791  0.001592   0.04141        77       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.888       0.832       0.834       0.637
     17/79     16.6G   0.03207  0.007965  0.001587   0.04162       103       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.887       0.832       0.836       0.638
     18/79     16.6G   0.03184  0.007968  0.001629   0.04143       102       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.887        0.84       0.842       0.635
     19/79     16.6G   0.03177  0.007939  0.001539   0.04125       105       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.879       0.836       0.827       0.636
     20/79     16.6G    0.0313  0.007789  0.001449   0.04053        86       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.902       0.842       0.853        0.66
     21/79     16.6G   0.03113  0.007776  0.001419   0.04032        79       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.884       0.845       0.834       0.637
     22/79     16.6G   0.03101  0.007646  0.001505   0.04016       102       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.894       0.835       0.838       0.645
     23/79     16.6G   0.03116  0.007816  0.001545   0.04052        77       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.864       0.854       0.841       0.647
     24/79     16.6G   0.03057  0.007738  0.001449   0.03976       113       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.869       0.844       0.835       0.642
     25/79     16.6G   0.03045  0.007681  0.001393   0.03953        76       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.885       0.844       0.836       0.652
     26/79     16.6G   0.03031  0.007759  0.001401   0.03947        75       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.882       0.848       0.841       0.655
     27/79     16.6G   0.03039  0.007828  0.001375   0.03959        73       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.895       0.832       0.849       0.663
     28/79     16.6G   0.03013  0.007641  0.001332    0.0391       102       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.882       0.853       0.844       0.659
     29/79     16.6G   0.02987   0.00765  0.001274   0.03879        92       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.896       0.841       0.845        0.66
     30/79     16.6G   0.02957  0.007621   0.00126   0.03845       127       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.894       0.849       0.852       0.669
     31/79     16.6G   0.02985  0.007665  0.001287    0.0388        89       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.898        0.84       0.848       0.666
     33/79     16.6G    0.0291  0.007554  0.001196   0.03785       120       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.898       0.846       0.851       0.668
     34/79     16.6G   0.02895  0.007451  0.001278   0.03768        93       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.884        0.86       0.856       0.673
     35/79     16.6G   0.02845  0.007434  0.001199   0.03709       127       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.898       0.853       0.861       0.682
     36/79     16.6G   0.02875  0.007513  0.001189   0.03745       101       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.895       0.854       0.855       0.677
     37/79     16.6G   0.02829   0.00742  0.001157   0.03686       102       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.899       0.868        0.86       0.679
     38/79     16.6G   0.02828  0.007494  0.001138   0.03691       106       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.895       0.859        0.86       0.684
     39/79     16.6G   0.02822   0.00737  0.001184   0.03678       115       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.896       0.846       0.849       0.676
     40/79     16.6G    0.0282  0.007337  0.001047   0.03659        83       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.893       0.863       0.853       0.682
     41/79     16.6G   0.02778  0.007388  0.001102   0.03627        83       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.903       0.864       0.855        0.68
     42/79     16.6G   0.02723  0.007376  0.001075   0.03568        97       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.901       0.859       0.863       0.686
     43/79     16.6G   0.02751  0.007377  0.000997   0.03588        99       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.887       0.874       0.867       0.688
     44/79     16.6G   0.02759  0.007126  0.001071   0.03579        87       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.902       0.855       0.867       0.691
     45/79     16.6G   0.02713  0.007168  0.001091   0.03539        92       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.895       0.863       0.855       0.685
     46/79     16.6G   0.02688  0.007018  0.001025   0.03492       110       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081         0.9       0.855       0.865       0.695
     47/79     16.6G   0.02653  0.007125 0.0009582   0.03461        86       512
     48/79     16.6G   0.02627   0.00703 0.0009608   0.03426        97       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.903       0.864       0.864       0.691
     49/79     16.6G   0.02663  0.007066  0.000989   0.03468       118       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.904       0.858       0.869       0.695
     50/79     16.6G   0.02589  0.007052 0.0009219   0.03386        83       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.902       0.868       0.869       0.695
     51/79     16.6G    0.0261  0.006989 0.0009679   0.03406        86       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081        0.91       0.862        0.87       0.697
     52/79     16.6G   0.02608  0.007004 0.0009319   0.03402        81       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.906       0.866        0.87         0.7
     53/79     16.6G   0.02575  0.006857 0.0009326   0.03354       103       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.905       0.866       0.873       0.701
     54/79     16.6G   0.02555  0.006881 0.0008876   0.03332       110       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081        0.91        0.86       0.866       0.697
     55/79     16.6G    0.0256   0.00687 0.0008233    0.0333       108       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081         0.9       0.867       0.875       0.704
     56/79     16.6G   0.02556  0.006961 0.0008927   0.03342        70       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081         0.9       0.866       0.875       0.706
     57/79     16.6G   0.02504  0.006787 0.0007799   0.03261        63       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.906       0.867       0.874       0.709
     58/79     16.6G   0.02496  0.006737 0.0008432   0.03254       110       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081         0.9       0.872       0.873       0.706
     59/79     16.6G   0.02496  0.006685 0.0008593   0.03251        76       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.909        0.87       0.875       0.708
     60/79     16.6G   0.02458  0.006748 0.0008318   0.03216        67       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.911       0.864       0.874       0.711
     61/79     16.6G   0.02452  0.006734 0.0007902   0.03205       122       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.909       0.868       0.875       0.711
     62/79     16.6G   0.02422  0.006549 0.0007748   0.03155       101       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.901       0.868       0.878       0.714
     63/79     16.6G   0.02407  0.006659 0.0008269   0.03155       121       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.903       0.862       0.876       0.709
     64/79     16.6G   0.02394  0.006484 0.0008308   0.03125        88       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.908       0.868       0.877       0.714
     65/79     16.6G   0.02387   0.00651 0.0008168    0.0312        99       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.909       0.867        0.88       0.714
     66/79     16.6G    0.0238  0.006468 0.0007055   0.03098        76       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.912       0.865       0.882       0.715
     67/79     16.6G   0.02364  0.006409 0.0007594   0.03081        91       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.915       0.865       0.882       0.715
     68/79     16.6G   0.02325  0.006264 0.0007115   0.03022       155       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.914       0.862       0.882       0.717
     69/79     16.6G   0.02338  0.006446 0.0007162   0.03054       113       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.897       0.874        0.88       0.717
     70/79     16.6G   0.02324  0.006347 0.0006713   0.03026       119       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081         0.9       0.872       0.879       0.715
     71/79     16.6G   0.02341  0.006388 0.0007474   0.03055       101       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.895       0.872        0.88       0.713
     72/79     16.6G   0.02285  0.006408 0.0006716   0.02993       106       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.901       0.873        0.88       0.714
     73/79     16.6G   0.02268  0.006182 0.0007327   0.02959        96       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.909       0.865        0.88       0.713
     74/79     16.6G   0.02253  0.006277 0.0006819   0.02949       114       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.909       0.869       0.881       0.716
     75/79     16.6G   0.02274  0.006218 0.0006566   0.02962       123       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.908       0.868       0.883       0.717
     76/79     16.6G   0.02271  0.006204 0.0006443   0.02956        74       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.897       0.875       0.883       0.717
     77/79     16.6G   0.02273  0.006286 0.0006503   0.02966        98       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.897       0.872       0.883       0.717
     78/79     16.6G   0.02258  0.006268 0.0006554   0.02951        65       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.899       0.872       0.882        0.72
     79/79     16.6G   0.02245  0.006137 0.0006392   0.02923       110       512
               Class      Images      Labels           P           R      [email protected]
                 all        1062        2081       0.905        0.87       0.882        0.72
                Fire        1062        1320       0.917       0.942       0.941       0.779
               Smoke        1062         761       0.893       0.797       0.822        0.66
/kaggle/working/yolov7/utils/general.py:802: FutureWarning: You are using `torch.load` with `weights_only=False` (the current default value), which uses the default pickle module implicitly. It is possible to construct malicious pickle data which will execute arbitrary code during unpickling (See https://github.com/pytorch/pytorch/blob/main/SECURITY.md#untrusted-models for more details). In a future release, the default value for `weights_only` will be flipped to `True`. This limits the functions that could be executed during unpickling. Arbitrary objects will no longer be allowed to be loaded via this mode unless they are explicitly allowlisted by the user via `torch.serialization.add_safe_globals`. We recommend you start setting `weights_only=True` for any use case where you don't have full control of the loaded file. Please open an issue on GitHub for any issues related to this experimental feature.
  x = torch.load(f, map_location=torch.device('cpu'))
Optimizer stripped from runs/train/exp8/weights/last.pt, 74.8MB
Optimizer stripped from runs/train/exp8/weights/best.pt, 74.8MB
InΒ [Β ]:
import matplotlib.pyplot as plt
import matplotlib.image as mpimg
img = mpimg.imread('/kaggle/working/yolov7/runs/train/exp8/confusion_matrix.png')
imgplot = plt.imshow(img)
plt.show()
No description has been provided for this image
InΒ [Β ]:
img = mpimg.imread('/kaggle/working/yolov7/runs/train/exp8/P_curve.png')
imgplot = plt.imshow(img)
plt.show()
No description has been provided for this image
InΒ [Β ]:
!python detect.py --weights /kaggle/working/yolov7/runs/train/exp8/weights/best.pt --img 640 --conf 0.35 --source /kaggle/working/yolov7/smokeandfire-2/test/images
InΒ [Β ]:
!python detect.py --weights /kaggle/working/yolov7/runs/train/exp8/weights/best.pt --source /kaggle/input/fireee/fire.109.jpg --img 640 --conf 0.25

test on new imagesΒΆ

InΒ [Β ]:
output_image_path = "/kaggle/working/yolov7/runs/detect/exp3/fire.109.jpg" 

output_image = cv2.imread(output_image_path)
output_image = cv2.cvtColor(output_image, cv2.COLOR_BGR2RGB)  
plt.figure(figsize=(8, 8))
plt.imshow(output_image)
plt.title('Detected Image - fire.109.jpg')
plt.axis('off')  
plt.show()
No description has been provided for this image
InΒ [Β ]:
# Running YOLOv5 prediction 
!python detect.py --weights /kaggle/working/yolov7/runs/train/exp8/weights/best.pt --source /kaggle/input/fire-and-smoke-detection-for-yolov8/train/images/0058_jpg.rf.629dad210eae7f57976d164974befbe2.jpg --img 640 --conf 0.25
InΒ [Β ]:
output_image_path = "/kaggle/working/yolov7/runs/detect/exp4/0058_jpg.rf.629dad210eae7f57976d164974befbe2.jpg" 
output_image = cv2.imread(output_image_path)
output_image = cv2.cvtColor(output_image, cv2.COLOR_BGR2RGB)  
plt.figure(figsize=(8, 8))
plt.imshow(output_image)
plt.title('Detected Image - fire.109.jpg')
plt.axis('off')  
plt.show()
No description has been provided for this image

yolo v7 best but its more complex

yolo v8-enhancementΒΆ

InΒ [Β ]:
!yolo train model=yolov8s.pt data='/kaggle/working/smokeandfire-2/data.yaml' epochs=120 imgsz=640 batch=32 augment=True lr0=0.005 lrf=0.01 weight_decay=0.0005 optimizer=SGD mosaic=True hsv_h=0.015 hsv_s=0.7 hsv_v=0.4 degrees=15 translate=0.1 scale=0.5 shear=0.2 flipud=0.5 fliplr=0.5 mixup=0.2
Ultralytics 8.3.48 πŸš€ Python-3.10.14 torch-2.4.0 CUDA:0 (Tesla P100-PCIE-16GB, 16269MiB)
engine/trainer: task=detect, mode=train, model=yolov8s.pt, data=/kaggle/working/smokeandfire-2/data.yaml, epochs=120, time=None, patience=100, batch=32, imgsz=640, save=True, save_period=-1, cache=False, device=None, workers=8, project=None, name=train2, exist_ok=False, pretrained=True, optimizer=SGD, verbose=True, seed=0, deterministic=True, single_cls=False, rect=False, cos_lr=False, close_mosaic=10, resume=False, amp=True, fraction=1.0, profile=False, freeze=None, multi_scale=False, overlap_mask=True, mask_ratio=4, dropout=0.0, val=True, split=val, save_json=False, save_hybrid=False, conf=None, iou=0.7, max_det=300, half=False, dnn=False, plots=True, source=None, vid_stride=1, stream_buffer=False, visualize=False, augment=True, agnostic_nms=False, classes=None, retina_masks=False, embed=None, show=False, save_frames=False, save_txt=False, save_conf=False, save_crop=False, show_labels=True, show_conf=True, show_boxes=True, line_width=None, format=torchscript, keras=False, optimize=False, int8=False, dynamic=False, simplify=True, opset=None, workspace=None, nms=False, lr0=0.005, lrf=0.01, momentum=0.937, weight_decay=0.0005, warmup_epochs=3.0, warmup_momentum=0.8, warmup_bias_lr=0.1, box=7.5, cls=0.5, dfl=1.5, pose=12.0, kobj=1.0, nbs=64, hsv_h=0.015, hsv_s=0.7, hsv_v=0.4, degrees=15, translate=0.1, scale=0.5, shear=0.2, perspective=0.0, flipud=0.5, fliplr=0.5, bgr=0.0, mosaic=True, mixup=0.2, copy_paste=0.0, copy_paste_mode=flip, auto_augment=randaugment, erasing=0.4, crop_fraction=1.0, cfg=None, tracker=botsort.yaml, save_dir=runs/detect/train2
Overriding model.yaml nc=80 with nc=2

                   from  n    params  module                                       arguments                     
  0                  -1  1       928  ultralytics.nn.modules.conv.Conv             [3, 32, 3, 2]                 
  1                  -1  1     18560  ultralytics.nn.modules.conv.Conv             [32, 64, 3, 2]                
  2                  -1  1     29056  ultralytics.nn.modules.block.C2f             [64, 64, 1, True]             
  3                  -1  1     73984  ultralytics.nn.modules.conv.Conv             [64, 128, 3, 2]               
  4                  -1  2    197632  ultralytics.nn.modules.block.C2f             [128, 128, 2, True]           
  5                  -1  1    295424  ultralytics.nn.modules.conv.Conv             [128, 256, 3, 2]              
  6                  -1  2    788480  ultralytics.nn.modules.block.C2f             [256, 256, 2, True]           
  7                  -1  1   1180672  ultralytics.nn.modules.conv.Conv             [256, 512, 3, 2]              
  8                  -1  1   1838080  ultralytics.nn.modules.block.C2f             [512, 512, 1, True]           
  9                  -1  1    656896  ultralytics.nn.modules.block.SPPF            [512, 512, 5]                 
 10                  -1  1         0  torch.nn.modules.upsampling.Upsample         [None, 2, 'nearest']          
 11             [-1, 6]  1         0  ultralytics.nn.modules.conv.Concat           [1]                           
 12                  -1  1    591360  ultralytics.nn.modules.block.C2f             [768, 256, 1]                 
 13                  -1  1         0  torch.nn.modules.upsampling.Upsample         [None, 2, 'nearest']          
 14             [-1, 4]  1         0  ultralytics.nn.modules.conv.Concat           [1]                           
 15                  -1  1    148224  ultralytics.nn.modules.block.C2f             [384, 128, 1]                 
 16                  -1  1    147712  ultralytics.nn.modules.conv.Conv             [128, 128, 3, 2]              
 17            [-1, 12]  1         0  ultralytics.nn.modules.conv.Concat           [1]                           
 18                  -1  1    493056  ultralytics.nn.modules.block.C2f             [384, 256, 1]                 
 19                  -1  1    590336  ultralytics.nn.modules.conv.Conv             [256, 256, 3, 2]              
 20             [-1, 9]  1         0  ultralytics.nn.modules.conv.Concat           [1]                           
 21                  -1  1   1969152  ultralytics.nn.modules.block.C2f             [768, 512, 1]                 
 22        [15, 18, 21]  1   2116822  ultralytics.nn.modules.head.Detect           [2, [128, 256, 512]]          
Model summary: 225 layers, 11,136,374 parameters, 11,136,358 gradients, 28.6 GFLOPs

Transferred 349/355 items from pretrained weights
TensorBoard: Start with 'tensorboard --logdir runs/detect/train2', view at http://localhost:6006/
Freezing layer 'model.22.dfl.conv.weight'
AMP: running Automatic Mixed Precision (AMP) checks...
AMP: checks passed βœ…
train: Scanning /kaggle/working/smokeandfire-2/train/labels.cache... 8243 images
WARNING ⚠️ Box and segment counts should be equal, but got len(segments) = 12, len(boxes) = 16365. To resolve this only boxes will be used and all segments will be removed. To avoid this please supply either a detect or segment dataset, not a detect-segment mixed dataset.
/opt/conda/lib/python3.10/site-packages/albumentations/__init__.py:24: UserWarning: A new version of Albumentations is available: 1.4.22 (you have 1.4.21). Upgrade using: pip install -U albumentations. To disable automatic update checks, set the environment variable NO_ALBUMENTATIONS_UPDATE to 1.
  check_for_updates()
albumentations: Blur(p=0.01, blur_limit=(3, 7)), MedianBlur(p=0.01, blur_limit=(3, 7)), ToGray(p=0.01, num_output_channels=3, method='weighted_average'), CLAHE(p=0.01, clip_limit=(1.0, 4.0), tile_grid_size=(8, 8))
/opt/conda/lib/python3.10/multiprocessing/popen_fork.py:66: RuntimeWarning: os.fork() was called. os.fork() is incompatible with multithreaded code, and JAX is multithreaded, so this will likely lead to a deadlock.
  self.pid = os.fork()
val: Scanning /kaggle/working/smokeandfire-2/valid/labels.cache... 1062 images, 
Plotting labels to runs/detect/train2/labels.jpg... 
optimizer: SGD(lr=0.005, momentum=0.937) with parameter groups 57 weight(decay=0.0), 64 weight(decay=0.0005), 63 bias(decay=0.0)
TensorBoard: model graph visualization added βœ…
Image sizes 640 train, 640 val
Using 4 dataloader workers
Logging results to runs/detect/train2
Starting training for 120 epochs...

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      1/120      8.04G      1.772      2.504      1.853         96        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.729      0.653      0.667      0.467

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      2/120      8.24G      1.449      1.591       1.59         76        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.822      0.746      0.783      0.552

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      3/120      8.29G      1.451      1.499      1.583         53        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.748      0.698      0.727      0.517

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      4/120      8.29G      1.473       1.54      1.608         90        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.834        0.7       0.75      0.503

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      5/120      8.29G      1.459      1.493       1.58         95        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.801      0.678      0.727      0.517

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      6/120      8.37G      1.424      1.442      1.568         62        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.849      0.776        0.8      0.571

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      7/120      8.38G      1.401      1.399      1.542         72        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.835      0.771      0.802      0.568

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      8/120      8.28G       1.39      1.377      1.545         82        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.843       0.78      0.811      0.581

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      9/120      8.28G      1.366       1.36      1.531         54        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.853      0.797      0.812      0.591

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     10/120      8.28G      1.352      1.331      1.516         91        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.844      0.813      0.822      0.602

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     11/120      8.28G      1.339      1.305      1.509         88        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.859      0.813       0.82      0.597

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     12/120       8.3G      1.326      1.287      1.496        112        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.88        0.8      0.823      0.611

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     13/120       8.3G      1.318      1.273      1.486         76        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.862      0.808      0.813        0.6

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     14/120      8.28G      1.312       1.26      1.488         80        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.85      0.808      0.828      0.618

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     15/120      8.36G      1.306      1.268      1.487        114        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.869      0.811      0.827      0.624

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     16/120      8.36G      1.284      1.238      1.477         91        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.878      0.833      0.837      0.619

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     17/120      8.36G       1.28      1.223      1.466         65        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.874      0.832      0.843      0.636

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     18/120      8.36G      1.277      1.224      1.472        137        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.862      0.818       0.83      0.627

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     19/120      8.37G      1.279      1.208      1.474         92        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.873      0.826      0.842      0.641

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     20/120      8.28G      1.273      1.205      1.464         92        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.877      0.835      0.851      0.648

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     21/120      8.29G      1.257      1.176       1.45         75        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.89      0.826      0.843      0.639

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     22/120      8.37G      1.266      1.183       1.45         87        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.876      0.837      0.845      0.648

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     23/120      8.37G      1.251      1.171       1.45        117        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.881      0.827      0.848      0.642

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     24/120      8.37G      1.243      1.165      1.436        129        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.874      0.839      0.854       0.66

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     25/120      8.29G      1.235      1.144      1.428         80        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.892      0.842      0.857      0.653

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     26/120       8.3G       1.24      1.145      1.424         78        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.876       0.84      0.856      0.653

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     27/120      8.37G       1.22      1.136      1.423         75        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.879      0.833      0.851      0.653

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     28/120      8.29G       1.23      1.132      1.431         71        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.883      0.846       0.86      0.662

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     29/120      8.29G       1.22      1.119      1.416         71        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.893       0.85      0.863       0.67

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     30/120       8.3G      1.215      1.109       1.41         70        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.88      0.855       0.86       0.67

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     31/120      8.38G      1.199      1.094      1.405         68        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.884      0.847      0.853      0.667

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     32/120      8.36G      1.205      1.104      1.405         75        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.89      0.846      0.857      0.668

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     33/120      8.37G      1.204      1.098      1.401         97        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.895      0.844      0.863       0.67

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     34/120      8.29G      1.203      1.087      1.405         72        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.898      0.843      0.863      0.673

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     35/120      8.29G       1.19      1.091      1.406         72        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.886      0.845      0.863      0.675

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     36/120      8.37G      1.171      1.061      1.387        100        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.887      0.847      0.861       0.68

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     37/120      8.29G      1.182      1.057      1.388         81        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.893      0.845      0.859      0.676

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     38/120       8.3G       1.19      1.073      1.398         74        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.898      0.844      0.863      0.678

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     39/120       8.3G      1.176       1.05      1.386         98        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.895      0.843       0.86      0.678

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     40/120      8.29G      1.164      1.033       1.38         77        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.903      0.844       0.86      0.675

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     41/120      8.37G      1.176      1.047      1.384         78        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.893      0.853       0.86      0.688

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     42/120      8.29G      1.166      1.035      1.374        111        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.895       0.85      0.861      0.686

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     43/120      8.29G      1.175      1.036      1.375        111        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.896       0.85       0.86      0.682

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     44/120      8.29G      1.151      1.017      1.369         67        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.894       0.85      0.865      0.688

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     45/120      8.28G      1.157      1.022       1.37         79        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.901       0.85      0.865      0.687

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     46/120      8.28G      1.153      1.004      1.363         94        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.891       0.85      0.867      0.689

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     47/120       8.3G      1.136      1.002      1.354         77        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081        0.9      0.855      0.866       0.69

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     48/120      8.29G      1.158      1.018      1.371         57        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.903      0.847      0.865      0.688

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     49/120      8.29G       1.14     0.9994      1.355         96        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081        0.9      0.856      0.871      0.693

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     50/120      8.29G      1.139     0.9899      1.358         91        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.893      0.856      0.865      0.691

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     51/120      8.37G      1.135     0.9923      1.353         76        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.901      0.864      0.867      0.693

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     52/120      8.29G      1.138     0.9864      1.356         99        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.906      0.856      0.869      0.693

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     53/120      8.37G       1.11     0.9659      1.333        103        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.905      0.853      0.867      0.697

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     54/120      8.37G      1.122     0.9754      1.344        100        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.906      0.858      0.866      0.697

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     55/120      8.29G      1.122     0.9694      1.347         78        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.91      0.858       0.87        0.7

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     56/120      8.29G      1.115      0.964       1.34         68        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.904      0.862      0.868      0.701

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     57/120      8.38G      1.115     0.9537      1.333         76        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.904      0.865      0.868      0.703

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     58/120       8.3G       1.11     0.9469      1.331         61        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.907      0.855      0.868      0.697

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     59/120      8.37G      1.111     0.9461      1.333        108        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.911      0.859      0.864      0.698

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     60/120      8.37G      1.125     0.9612       1.34        117        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.908      0.862      0.874      0.704

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     61/120      8.37G      1.105     0.9402      1.327         69        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.898      0.866      0.873      0.705

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     62/120      8.29G       1.11     0.9479      1.329         66        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.901      0.866      0.871      0.703

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     63/120      8.37G      1.093     0.9297       1.32         80        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.905      0.867      0.874      0.703

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     64/120      8.37G      1.088     0.9111       1.31         58        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.903      0.864      0.872      0.699

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     65/120       8.3G      1.088     0.9161       1.31         86        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.906       0.86      0.872      0.705

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     66/120      8.37G      1.088     0.9072       1.31        128        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.914      0.861      0.869      0.702

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     67/120      8.37G      1.064     0.8933      1.298         53        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.914      0.868      0.872      0.703

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     68/120      8.37G       1.09     0.9137      1.316         97        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.907      0.865      0.872      0.703

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     69/120      8.29G      1.072     0.8963      1.301         98        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.91      0.859      0.874      0.706

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     70/120       8.3G      1.073     0.8986      1.307         68        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.906      0.862      0.872      0.701

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     71/120      8.29G      1.073     0.8938      1.302         71        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.902      0.868      0.872      0.704

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     72/120      8.38G      1.079     0.8943      1.312         75        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.895      0.869      0.873      0.705

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     73/120      8.37G      1.069     0.8782      1.302         67        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.902      0.864      0.871      0.704

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     74/120       8.3G       1.07     0.8827      1.297         73        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.902      0.861      0.871      0.703

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     75/120      8.38G      1.065     0.8809      1.295         84        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.91      0.859      0.871      0.706

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     76/120      8.37G      1.054     0.8663      1.284         87        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.915      0.854      0.872      0.708

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     77/120      8.37G      1.059     0.8701      1.294         75        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.913      0.862      0.875      0.708

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     78/120      7.91G      1.055     0.8605      1.287        102        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.91      0.856      0.874      0.707

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     79/120       8.3G      1.045     0.8522      1.283        101        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.914      0.853      0.872      0.706

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     80/120       8.3G      1.041     0.8417      1.279        101        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.906      0.856      0.872      0.706

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     81/120      8.37G      1.037     0.8555      1.286         94        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.908      0.859      0.873      0.709

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     82/120      8.37G      1.052     0.8587      1.284         87        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.904      0.859      0.873      0.708

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     83/120      8.29G      1.034     0.8497      1.274         66        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.906      0.858      0.873      0.709

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     84/120       8.3G      1.043     0.8464      1.283         95        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.902      0.861      0.873      0.709

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     85/120      8.37G      1.037     0.8386      1.276         73        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.893      0.866      0.873       0.71

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     86/120      8.28G      1.036     0.8349      1.277         71        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081        0.9      0.863      0.874       0.71

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     87/120       8.3G      1.029     0.8345      1.271         80        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.898      0.861      0.873      0.711

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     88/120       8.3G       1.02     0.8315      1.269         94        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.906      0.861      0.874       0.71

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     89/120      8.29G      1.011     0.8078      1.259         57        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.901      0.865      0.874       0.71

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     90/120       8.3G      1.021     0.8177      1.259         91        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.901      0.863      0.874      0.712

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     91/120      8.37G      1.007     0.8019      1.256         53        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.902      0.862      0.874      0.713

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     92/120      8.37G      1.014     0.8053      1.263        105        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.903       0.86      0.875      0.713

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     93/120      7.92G      1.019      0.817      1.261        103        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081        0.9      0.865      0.876      0.715

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     94/120      8.29G     0.9994     0.7937      1.245         56        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.896      0.868      0.875      0.713

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     95/120      8.29G      1.006     0.8044      1.248         77        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.897      0.867      0.876      0.712

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     96/120      8.29G      1.013      0.809      1.255        122        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.896      0.869      0.877      0.712

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     97/120      8.37G     0.9935     0.7794      1.242         91        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.896      0.866      0.876      0.712

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     98/120       8.3G     0.9931      0.782      1.243         87        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.897      0.868      0.876      0.711

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     99/120      7.91G     0.9949     0.7824      1.242         72        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.894      0.866      0.876      0.713

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
    100/120      8.28G     0.9929     0.7789      1.241         61        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.895      0.866      0.877      0.712

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
    101/120      8.37G     0.9967     0.7906      1.248         90        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.894      0.866      0.876      0.712

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
    102/120      8.28G     0.9856     0.7765      1.239         88        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.895      0.863      0.875      0.711

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
    103/120      8.28G       0.98     0.7715       1.24         59        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.895      0.859      0.875      0.712

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
    104/120      8.28G     0.9682     0.7546      1.231         93        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.895      0.858      0.875      0.712

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
    105/120      8.35G      0.982     0.7707      1.239        111        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.895      0.861      0.876      0.713

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
    106/120      8.37G     0.9774     0.7621      1.235         96        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.895      0.863      0.876      0.713

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
    107/120      8.35G     0.9844     0.7555      1.239         73        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.895      0.861      0.875      0.713

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
    108/120      8.28G     0.9711     0.7594      1.234         85        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.897       0.86      0.875      0.714

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
    109/120      8.28G     0.9674     0.7519      1.226         78        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.894      0.862      0.875      0.714

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
    110/120      8.39G     0.9586     0.7433      1.225         67        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.894      0.862      0.875      0.713
Closing dataloader mosaic
albumentations: Blur(p=0.01, blur_limit=(3, 7)), MedianBlur(p=0.01, blur_limit=(3, 7)), ToGray(p=0.01, num_output_channels=3, method='weighted_average'), CLAHE(p=0.01, clip_limit=(1.0, 4.0), tile_grid_size=(8, 8))
/opt/conda/lib/python3.10/multiprocessing/popen_fork.py:66: RuntimeWarning: os.fork() was called. os.fork() is incompatible with multithreaded code, and JAX is multithreaded, so this will likely lead to a deadlock.
  self.pid = os.fork()

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
    111/120      8.36G     0.8537     0.5345      1.137         44        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.897      0.863      0.875      0.712

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
    112/120      8.28G     0.8322     0.5039      1.123         27        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.896      0.862      0.875      0.712

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
    113/120      8.36G     0.8322     0.4976      1.124         34        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.897      0.862      0.875      0.712

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
    114/120      8.28G     0.8217     0.4903      1.117         34        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.897       0.86      0.875      0.713

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
    115/120      8.35G     0.8126     0.4803      1.112         41        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.896      0.861      0.875      0.713

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
    116/120      8.37G     0.8127     0.4726      1.112         33        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.895      0.861      0.875      0.713

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
    117/120      8.28G     0.8041     0.4765      1.105         35        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.896      0.859      0.875      0.713

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
    118/120      8.29G     0.8052     0.4723      1.105         43        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.895      0.859      0.876      0.714

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
    119/120      8.29G     0.7986     0.4622      1.101         39        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.896       0.86      0.875      0.714

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
    120/120      8.29G     0.7987      0.461      1.105         35        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.896       0.86      0.875      0.715

120 epochs completed in 4.772 hours.
Optimizer stripped from runs/detect/train2/weights/last.pt, 22.5MB
Optimizer stripped from runs/detect/train2/weights/best.pt, 22.5MB

Validating runs/detect/train2/weights/best.pt...
Ultralytics 8.3.48 πŸš€ Python-3.10.14 torch-2.4.0 CUDA:0 (Tesla P100-PCIE-16GB, 16269MiB)
Model summary (fused): 168 layers, 11,126,358 parameters, 0 gradients, 28.4 GFLOPs
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.898      0.862      0.879      0.718
                  Fire        859       1320      0.911      0.938      0.939      0.765
                 Smoke        559        761      0.885      0.787      0.819       0.67
Speed: 0.1ms preprocess, 10.0ms inference, 0.0ms loss, 0.7ms postprocess per image
Results saved to runs/detect/train2
πŸ’‘ Learn more at https://docs.ultralytics.com/modes/train
InΒ [Β ]:
import matplotlib.pyplot as plt
import matplotlib.image as mpimg

img = mpimg.imread('/kaggle/working/runs/detect/train2/results.png')
imgplot = plt.imshow(img)
plt.show()
No description has been provided for this image
InΒ [Β ]:
img = mpimg.imread('/kaggle/working/runs/detect/train2/P_curve.png')
imgplot = plt.imshow(img)
plt.show()
No description has been provided for this image
InΒ [Β ]:
!yolo task=detect mode=predict model="/kaggle/working/runs/detect/train2/weights/best.pt" device =0 source="/kaggle/working/smokeandfire-2/test/images"
InΒ [Β ]:
!yolo predict model="/kaggle/working/runs/detect/train2/weights/best.pt", source="/kaggle/input/fire-and-smoke-detection-for-yolov8/test/images/40_jpg.rf.61555964ef797e1c3989f692641d30f7.jpg"
WARNING ⚠️ argument 'model=/kaggle/working/runs/detect/train2/weights/best.pt,' does not require trailing comma ',', updating to 'model=/kaggle/working/runs/detect/train2/weights/best.pt'.
Ultralytics 8.3.48 πŸš€ Python-3.10.14 torch-2.4.0 CUDA:0 (Tesla P100-PCIE-16GB, 16269MiB)
Model summary (fused): 168 layers, 11,126,358 parameters, 0 gradients, 28.4 GFLOPs

image 1/1 /kaggle/input/fire-and-smoke-detection-for-yolov8/test/images/40_jpg.rf.61555964ef797e1c3989f692641d30f7.jpg: 640x640 1 Smoke, 8.5ms
Speed: 6.6ms preprocess, 8.5ms inference, 164.9ms postprocess per image at shape (1, 3, 640, 640)
Results saved to runs/detect/predict4
πŸ’‘ Learn more at https://docs.ultralytics.com/modes/predict
InΒ [Β ]:
output_image_path = "/kaggle/working/runs/detect/predict4/40_jpg.rf.61555964ef797e1c3989f692641d30f7.jpg"  
output_image = cv2.imread(output_image_path)
output_image = cv2.cvtColor(output_image, cv2.COLOR_BGR2RGB)  

# Display the output image
plt.figure(figsize=(8, 8))
plt.imshow(output_image)
plt.title('Detected Image - fire.109.jpg')
plt.axis('off')
plt.show()
No description has been provided for this image
InΒ [Β ]:
!yolo predict model="/kaggle/working/runs/detect/train2/weights/best.pt", source="/kaggle/input/fireimage/fire.109.jpg"
WARNING ⚠️ argument 'model=/kaggle/working/runs/detect/train2/weights/best.pt,' does not require trailing comma ',', updating to 'model=/kaggle/working/runs/detect/train2/weights/best.pt'.
Ultralytics 8.3.48 πŸš€ Python-3.10.14 torch-2.4.0 CUDA:0 (Tesla P100-PCIE-16GB, 16269MiB)
Model summary (fused): 168 layers, 11,126,358 parameters, 0 gradients, 28.4 GFLOPs

image 1/1 /kaggle/input/fireimage/fire.109.jpg: 384x640 2 Fires, 51.7ms
Speed: 5.1ms preprocess, 51.7ms inference, 155.0ms postprocess per image at shape (1, 3, 384, 640)
Results saved to runs/detect/predict5
πŸ’‘ Learn more at https://docs.ultralytics.com/modes/predict
InΒ [Β ]:
output_image_path = "/kaggle/working/runs/detect/predict5/fire.109.jpg"  
output_image = cv2.imread(output_image_path)
output_image = cv2.cvtColor(output_image, cv2.COLOR_BGR2RGB)  
plt.figure(figsize=(8, 8))
plt.imshow(output_image)
plt.title('Detected Image - fire.109.jpg')
plt.axis('off') 
plt.show()
No description has been provided for this image

yolo v11ΒΆ

InΒ [3]:
!yolo train model=yolo11n.pt data='/kaggle/working/smokeandfire-2/data.yaml' epochs=120 imgsz=512 batch=32 augment=True 
Downloading https://github.com/ultralytics/assets/releases/download/v8.3.0/yolo11n.pt to 'yolo11n.pt'...
100%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| 5.35M/5.35M [00:00<00:00, 94.6MB/s]
Ultralytics 8.3.71 πŸš€ Python-3.10.14 torch-2.4.0 CUDA:0 (Tesla P100-PCIE-16GB, 16269MiB)
engine/trainer: task=detect, mode=train, model=yolo11n.pt, data=/kaggle/working/smokeandfire-2/data.yaml, epochs=120, time=None, patience=100, batch=32, imgsz=512, save=True, save_period=-1, cache=False, device=None, workers=8, project=None, name=train, exist_ok=False, pretrained=True, optimizer=auto, verbose=True, seed=0, deterministic=True, single_cls=False, rect=False, cos_lr=False, close_mosaic=10, resume=False, amp=True, fraction=1.0, profile=False, freeze=None, multi_scale=False, overlap_mask=True, mask_ratio=4, dropout=0.0, val=True, split=val, save_json=False, save_hybrid=False, conf=None, iou=0.7, max_det=300, half=False, dnn=False, plots=True, source=None, vid_stride=1, stream_buffer=False, visualize=False, augment=True, agnostic_nms=False, classes=None, retina_masks=False, embed=None, show=False, save_frames=False, save_txt=False, save_conf=False, save_crop=False, show_labels=True, show_conf=True, show_boxes=True, line_width=None, format=torchscript, keras=False, optimize=False, int8=False, dynamic=False, simplify=True, opset=None, workspace=None, nms=False, lr0=0.01, lrf=0.01, momentum=0.937, weight_decay=0.0005, warmup_epochs=3.0, warmup_momentum=0.8, warmup_bias_lr=0.1, box=7.5, cls=0.5, dfl=1.5, pose=12.0, kobj=1.0, nbs=64, hsv_h=0.015, hsv_s=0.7, hsv_v=0.4, degrees=0.0, translate=0.1, scale=0.5, shear=0.0, perspective=0.0, flipud=0.0, fliplr=0.5, bgr=0.0, mosaic=1.0, mixup=0.0, copy_paste=0.0, copy_paste_mode=flip, auto_augment=randaugment, erasing=0.4, crop_fraction=1.0, cfg=None, tracker=botsort.yaml, save_dir=runs/detect/train
Downloading https://ultralytics.com/assets/Arial.ttf to '/root/.config/Ultralytics/Arial.ttf'...
100%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| 755k/755k [00:00<00:00, 22.0MB/s]
Overriding model.yaml nc=80 with nc=2

                   from  n    params  module                                       arguments                     
  0                  -1  1       464  ultralytics.nn.modules.conv.Conv             [3, 16, 3, 2]                 
  1                  -1  1      4672  ultralytics.nn.modules.conv.Conv             [16, 32, 3, 2]                
  2                  -1  1      6640  ultralytics.nn.modules.block.C3k2            [32, 64, 1, False, 0.25]      
  3                  -1  1     36992  ultralytics.nn.modules.conv.Conv             [64, 64, 3, 2]                
  4                  -1  1     26080  ultralytics.nn.modules.block.C3k2            [64, 128, 1, False, 0.25]     
  5                  -1  1    147712  ultralytics.nn.modules.conv.Conv             [128, 128, 3, 2]              
  6                  -1  1     87040  ultralytics.nn.modules.block.C3k2            [128, 128, 1, True]           
  7                  -1  1    295424  ultralytics.nn.modules.conv.Conv             [128, 256, 3, 2]              
  8                  -1  1    346112  ultralytics.nn.modules.block.C3k2            [256, 256, 1, True]           
  9                  -1  1    164608  ultralytics.nn.modules.block.SPPF            [256, 256, 5]                 
 10                  -1  1    249728  ultralytics.nn.modules.block.C2PSA           [256, 256, 1]                 
 11                  -1  1         0  torch.nn.modules.upsampling.Upsample         [None, 2, 'nearest']          
 12             [-1, 6]  1         0  ultralytics.nn.modules.conv.Concat           [1]                           
 13                  -1  1    111296  ultralytics.nn.modules.block.C3k2            [384, 128, 1, False]          
 14                  -1  1         0  torch.nn.modules.upsampling.Upsample         [None, 2, 'nearest']          
 15             [-1, 4]  1         0  ultralytics.nn.modules.conv.Concat           [1]                           
 16                  -1  1     32096  ultralytics.nn.modules.block.C3k2            [256, 64, 1, False]           
 17                  -1  1     36992  ultralytics.nn.modules.conv.Conv             [64, 64, 3, 2]                
 18            [-1, 13]  1         0  ultralytics.nn.modules.conv.Concat           [1]                           
 19                  -1  1     86720  ultralytics.nn.modules.block.C3k2            [192, 128, 1, False]          
 20                  -1  1    147712  ultralytics.nn.modules.conv.Conv             [128, 128, 3, 2]              
 21            [-1, 10]  1         0  ultralytics.nn.modules.conv.Concat           [1]                           
 22                  -1  1    378880  ultralytics.nn.modules.block.C3k2            [384, 256, 1, True]           
 23        [16, 19, 22]  1    431062  ultralytics.nn.modules.head.Detect           [2, [64, 128, 256]]           
YOLO11n summary: 319 layers, 2,590,230 parameters, 2,590,214 gradients, 6.4 GFLOPs

Transferred 448/499 items from pretrained weights
TensorBoard: Start with 'tensorboard --logdir runs/detect/train', view at http://localhost:6006/
Freezing layer 'model.23.dfl.conv.weight'
AMP: running Automatic Mixed Precision (AMP) checks...
AMP: checks passed βœ…
train: Scanning /kaggle/working/smokeandfire-2/train/labels... 8243 images, 11 b
train: New cache created: /kaggle/working/smokeandfire-2/train/labels.cache
WARNING ⚠️ Box and segment counts should be equal, but got len(segments) = 12, len(boxes) = 16365. To resolve this only boxes will be used and all segments will be removed. To avoid this please supply either a detect or segment dataset, not a detect-segment mixed dataset.
/opt/conda/lib/python3.10/site-packages/albumentations/__init__.py:24: UserWarning: A new version of Albumentations is available: 2.0.3 (you have 1.4.21). Upgrade using: pip install -U albumentations. To disable automatic update checks, set the environment variable NO_ALBUMENTATIONS_UPDATE to 1.
  check_for_updates()
albumentations: Blur(p=0.01, blur_limit=(3, 7)), MedianBlur(p=0.01, blur_limit=(3, 7)), ToGray(p=0.01, num_output_channels=3, method='weighted_average'), CLAHE(p=0.01, clip_limit=(1.0, 4.0), tile_grid_size=(8, 8))
/opt/conda/lib/python3.10/multiprocessing/popen_fork.py:66: RuntimeWarning: os.fork() was called. os.fork() is incompatible with multithreaded code, and JAX is multithreaded, so this will likely lead to a deadlock.
  self.pid = os.fork()
val: Scanning /kaggle/working/smokeandfire-2/valid/labels... 1062 images, 3 back
val: New cache created: /kaggle/working/smokeandfire-2/valid/labels.cache
/opt/conda/lib/python3.10/multiprocessing/popen_fork.py:66: RuntimeWarning: os.fork() was called. os.fork() is incompatible with multithreaded code, and JAX is multithreaded, so this will likely lead to a deadlock.
  self.pid = os.fork()
Plotting labels to runs/detect/train/labels.jpg... 
optimizer: 'optimizer=auto' found, ignoring 'lr0=0.01' and 'momentum=0.937' and determining best 'optimizer', 'lr0' and 'momentum' automatically... 
optimizer: SGD(lr=0.01, momentum=0.9) with parameter groups 81 weight(decay=0.0), 88 weight(decay=0.0005), 87 bias(decay=0.0)
TensorBoard: model graph visualization added βœ…
Image sizes 512 train, 512 val
Using 4 dataloader workers
Logging results to runs/detect/train
Starting training for 120 epochs...

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      1/120      3.26G      1.436       2.61      1.466        110        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.707      0.572       0.64       0.44

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      2/120      3.31G      1.362       1.72      1.379         68        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.814      0.696      0.749      0.537

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      3/120      3.31G      1.419      1.631      1.417         42        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.667      0.405      0.446      0.296

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      4/120       3.3G      1.478      1.639      1.473         66        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.768      0.611      0.669      0.478

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      5/120       3.3G      1.433      1.515      1.448         69        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.773      0.678      0.712      0.518

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      6/120       3.3G      1.398      1.441      1.422         65        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.817      0.735      0.767      0.556

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      7/120      3.29G      1.358      1.372      1.403         66        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.824      0.697      0.742      0.548

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      8/120       3.3G      1.339      1.326      1.384         54        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.82      0.766      0.789      0.586

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      9/120      3.33G      1.305      1.278      1.371         49        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.848      0.774        0.8      0.595

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     10/120      3.29G      1.305      1.286      1.371         79        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.834      0.789      0.807      0.605

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     11/120      3.27G      1.265      1.225      1.346         59        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.858      0.809      0.819      0.611

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     12/120      3.28G      1.259      1.214      1.339         81        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.859      0.783      0.809      0.615

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     13/120       3.3G      1.257      1.196      1.343         57        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.839      0.778      0.804      0.614

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     14/120      3.31G      1.238      1.175      1.326         66        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.87      0.791      0.826      0.623

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     15/120      3.27G      1.227      1.151      1.325         78        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.857      0.815       0.83      0.635

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     16/120      3.27G      1.213      1.123      1.311         68        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.854      0.812      0.843      0.637

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     17/120      3.28G      1.223      1.133      1.314         68        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.865      0.824      0.844      0.641

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     18/120      3.29G      1.187      1.096      1.297         75        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.87      0.825      0.834      0.639

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     19/120      3.29G      1.207      1.109      1.304         53        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.871      0.841      0.857      0.658

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     20/120       3.3G       1.18       1.08      1.292         82        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.879      0.831      0.851      0.663

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     21/120      3.27G      1.187      1.085      1.298         62        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.871      0.831       0.85      0.658

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     22/120      3.27G       1.19      1.068      1.288         79        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.882      0.832      0.848      0.659

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     23/120      3.27G      1.165      1.049      1.281         71        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.869      0.839      0.843      0.659

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     24/120       3.3G      1.162      1.047      1.276         75        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.884      0.822      0.852       0.66

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     25/120       3.3G      1.148      1.021       1.27         51        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.884      0.833      0.855      0.664

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     26/120       3.3G      1.156      1.037      1.272         81        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.882      0.838      0.852      0.666

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     27/120       3.3G      1.146      1.022      1.267         73        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.879      0.846      0.857       0.67

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     28/120       3.3G      1.136      1.008      1.261         58        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.872      0.838      0.855      0.671

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     29/120      3.31G      1.137      1.009      1.264         68        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.88      0.839      0.855      0.676

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     30/120      3.27G      1.142      1.005      1.261         40        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.872      0.845      0.854      0.668

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     31/120       3.3G      1.128     0.9905      1.255         47        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.898      0.846      0.863      0.684

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     32/120       3.3G      1.113     0.9722      1.245         68        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.884      0.853      0.863      0.675

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     33/120       3.3G       1.12     0.9904      1.249         77        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.879      0.856      0.864      0.679

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     34/120       3.3G      1.099     0.9649      1.235         47        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.893      0.847      0.857      0.679

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     35/120      3.28G      1.111     0.9657      1.241         54        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.899      0.844      0.858      0.685

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     36/120       3.3G      1.118     0.9633      1.244         70        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.896      0.841      0.858      0.679

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     37/120      3.27G      1.111     0.9528      1.238         41        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.897      0.852      0.868      0.686

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     38/120      3.25G      1.089     0.9448       1.23         62        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.898      0.862      0.867       0.69

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     39/120      3.28G       1.09     0.9326      1.227         56        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.89      0.856      0.871      0.688

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     40/120      3.27G      1.088     0.9277      1.225         77        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.892      0.851      0.867      0.691

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     41/120      3.31G      1.085     0.9331      1.223         54        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.896      0.855      0.862      0.685

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     42/120       3.3G      1.086      0.921      1.225         61        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.888      0.863      0.868       0.69

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     43/120      3.27G      1.078     0.9189       1.22         56        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.894      0.865      0.864      0.691

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     44/120       3.3G      1.077     0.9252      1.222         65        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.897      0.864      0.872      0.692

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     45/120      3.31G      1.072     0.9073       1.22         61        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.895      0.859      0.868      0.691

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     46/120      3.27G      1.066     0.8929       1.21         74        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.899      0.859      0.872      0.693

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     47/120      3.29G       1.06     0.8987      1.211         55        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.906      0.862      0.873      0.694

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     48/120       3.3G      1.082     0.9064      1.219         63        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.905      0.856      0.869      0.693

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     49/120      3.31G      1.059     0.8844      1.205         74        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.901       0.86      0.871      0.696

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     50/120      3.29G       1.06     0.8844      1.207         70        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.903       0.86      0.872      0.694

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     51/120      3.31G      1.041      0.874      1.193         69        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.905      0.866      0.878      0.703

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     52/120      3.31G      1.044     0.8695      1.201         71        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.897      0.862      0.872      0.702

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     53/120      3.29G      1.049     0.8753      1.202         56        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.906      0.866      0.876      0.703

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     54/120      3.31G      1.045     0.8659        1.2         79        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.904      0.862      0.874      0.701

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     55/120      3.31G      1.038     0.8652      1.195         59        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.905      0.866      0.871      0.701

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     56/120      3.27G      1.031     0.8554      1.193         76        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.903      0.868      0.873      0.698

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     57/120      3.31G      1.037     0.8555      1.191         63        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.895      0.867      0.873        0.7

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     58/120      3.27G      1.034     0.8462      1.191         98        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.901      0.859      0.872      0.703

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     59/120      3.29G      1.032     0.8382       1.19        120        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.901      0.869      0.878      0.704

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     60/120       3.3G      1.027     0.8497      1.188         73        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.901      0.868      0.877      0.703

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     61/120       3.3G      1.029     0.8432      1.185         63        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.905      0.863      0.878      0.708

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     62/120       3.3G      1.016      0.827      1.179         63        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.904      0.869      0.877      0.702

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     63/120       3.3G      1.016     0.8355      1.184         73        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.909      0.864      0.879      0.707

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     64/120      3.29G      1.004     0.8192      1.171         61        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.896      0.868      0.878      0.707

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     65/120      3.27G       1.02     0.8247      1.176         97        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.899      0.869      0.875      0.705

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     66/120      3.27G      1.018     0.8184      1.182         56        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.903      0.872      0.876      0.706

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     67/120      3.29G     0.9944     0.7994      1.167         79        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.902      0.867      0.873      0.704

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     68/120       3.3G      1.006      0.802      1.174         78        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.908      0.864      0.874      0.708

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     69/120       3.3G     0.9867      0.788      1.159         68        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.904      0.865      0.874      0.705

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     70/120      3.29G     0.9927     0.8019      1.162         75        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.898      0.867      0.874      0.707

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     71/120      3.27G     0.9946     0.7969      1.161         79        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.906      0.865      0.875      0.708

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     72/120       3.3G     0.9899     0.7875      1.161         64        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.906      0.867      0.875       0.71

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     73/120      3.27G     0.9975     0.7977      1.169         44        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.906      0.866      0.875       0.71

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     74/120      3.29G     0.9864     0.7849       1.16         72        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.904      0.868      0.876      0.713

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     75/120       3.3G     0.9777     0.7802      1.158         69        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.905      0.868      0.878      0.713

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     76/120      3.27G     0.9854     0.7775      1.157         63        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.907      0.869      0.878      0.713

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     77/120       3.3G     0.9822     0.7828      1.159         65        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.906      0.869      0.878      0.714

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     78/120      3.27G     0.9772     0.7644      1.151         68        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.907      0.869       0.88      0.716

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     79/120      3.27G     0.9696      0.764      1.148         54        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.907      0.866      0.878      0.714

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     80/120      3.29G     0.9681     0.7653      1.148         64        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.909      0.868      0.879      0.716

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     81/120      3.31G     0.9664     0.7535      1.142         84        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.906       0.87      0.878      0.715

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     82/120      3.31G     0.9643      0.754      1.145         85        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.908      0.871      0.877      0.715

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     83/120      3.29G     0.9526     0.7361      1.138         68        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.905      0.872      0.877      0.714

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     84/120      3.27G     0.9588     0.7382      1.138         77        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.907      0.871      0.877      0.715

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     85/120      3.29G     0.9594     0.7385      1.143         82        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.91      0.873       0.88      0.718

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     86/120       3.3G      0.958     0.7438      1.141         62        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.907      0.873       0.88      0.718

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     87/120      3.28G     0.9399     0.7295      1.131         86        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.904      0.869      0.879      0.717

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     88/120      3.31G     0.9461     0.7319      1.137         50        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.905      0.867       0.88      0.718

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     89/120       3.3G     0.9431     0.7254      1.129         72        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.907      0.868      0.881      0.719

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     90/120      3.27G     0.9373     0.7128      1.125         70        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.907       0.87       0.88      0.718

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     91/120      3.29G     0.9316     0.7105      1.125         46        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.908      0.868       0.88      0.718

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     92/120       3.3G     0.9318     0.7071       1.13         60        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.906      0.867       0.88      0.718

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     93/120      3.31G     0.9307     0.7139      1.125         61        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.91      0.867      0.882      0.719

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     94/120      3.29G     0.9355     0.7159      1.127         81        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.908       0.87      0.881       0.72

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     95/120      3.27G     0.9325     0.7044      1.123         92        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.906      0.871      0.883      0.721

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     96/120      3.29G     0.9364     0.7062      1.124         75        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.906      0.869      0.881      0.721

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     97/120       3.3G     0.9243     0.6948      1.117         55        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.906      0.867      0.881       0.72

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     98/120       3.3G     0.9179     0.6887      1.119         59        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.909      0.868      0.882      0.722

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     99/120      3.31G     0.9128     0.6816      1.113         65        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.909      0.868      0.881       0.72

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
    100/120      3.25G     0.9169     0.6878      1.114         74        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.91      0.865       0.88      0.719

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
    101/120      3.27G     0.9099     0.6768      1.111         40        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.909      0.866      0.878      0.719

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
    102/120      3.34G     0.8971     0.6639      1.102         76        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.907      0.867      0.877      0.717

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
    103/120      3.31G     0.9041     0.6708      1.109         65        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.908      0.867      0.878      0.718

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
    104/120       3.3G     0.8913      0.661      1.101         67        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.907      0.866      0.878      0.717

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
    105/120      3.28G     0.8959     0.6578      1.102         71        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.909      0.867      0.878      0.717

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
    106/120       3.3G       0.89     0.6575      1.102         71        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.907      0.867      0.879      0.717

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
    107/120      3.31G      0.905      0.664      1.106         61        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.908      0.865      0.878      0.717

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
    108/120       3.3G     0.8902     0.6515        1.1         77        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.908      0.865      0.877      0.717

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
    109/120      3.31G     0.8954     0.6533      1.101         73        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.907      0.864      0.878      0.717

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
    110/120      3.29G     0.8811      0.646      1.097         60        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.908      0.867      0.878      0.717
Closing dataloader mosaic
albumentations: Blur(p=0.01, blur_limit=(3, 7)), MedianBlur(p=0.01, blur_limit=(3, 7)), ToGray(p=0.01, num_output_channels=3, method='weighted_average'), CLAHE(p=0.01, clip_limit=(1.0, 4.0), tile_grid_size=(8, 8))
/opt/conda/lib/python3.10/multiprocessing/popen_fork.py:66: RuntimeWarning: os.fork() was called. os.fork() is incompatible with multithreaded code, and JAX is multithreaded, so this will likely lead to a deadlock.
  self.pid = os.fork()

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
    111/120      3.27G     0.8847     0.5868      1.083         45        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.907      0.866      0.878      0.717

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
    112/120      3.25G     0.8675     0.5623      1.075         28        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.905      0.866      0.877      0.717

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
    113/120      3.25G     0.8625     0.5502       1.07         34        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.904      0.866      0.878      0.717

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
    114/120      3.27G     0.8532     0.5476      1.065         34        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.903      0.866      0.877      0.717

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
    115/120      3.27G     0.8476      0.537      1.063         41        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.902      0.866      0.878      0.717

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
    116/120      3.27G     0.8397     0.5279      1.059         33        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.903      0.866      0.878      0.717

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
    117/120      3.27G     0.8393     0.5274      1.059         34        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.903      0.865      0.878      0.717

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
    118/120      3.27G     0.8387     0.5298       1.06         43        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.903      0.864      0.878      0.717

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
    119/120       3.3G     0.8296     0.5176      1.055         39        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.904      0.864      0.878      0.717

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
    120/120      3.28G      0.824     0.5132      1.054         35        512: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.905      0.865      0.878      0.716

120 epochs completed in 2.325 hours.
Optimizer stripped from runs/detect/train/weights/last.pt, 5.5MB
Optimizer stripped from runs/detect/train/weights/best.pt, 5.5MB

Validating runs/detect/train/weights/best.pt...
Ultralytics 8.3.71 πŸš€ Python-3.10.14 torch-2.4.0 CUDA:0 (Tesla P100-PCIE-16GB, 16269MiB)
YOLO11n summary (fused): 238 layers, 2,582,542 parameters, 0 gradients, 6.3 GFLOPs
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.895      0.871      0.876      0.715
                  Fire        859       1320      0.917      0.943       0.94      0.773
                 Smoke        559        761      0.874        0.8      0.812      0.657
Speed: 0.1ms preprocess, 3.5ms inference, 0.0ms loss, 0.8ms postprocess per image
Results saved to runs/detect/train
πŸ’‘ Learn more at https://docs.ultralytics.com/modes/train

yolo v 12ΒΆ

InΒ [Β ]:
!pip install roboflow

from roboflow import Roboflow
rf = Roboflow(api_key="GZBlBPlRdRvB6uR7BqaS")
project = rf.workspace("detection-e83li").project("smokeandfire")
version = project.version(2)
dataset = version.download("yolov12")
                
InΒ [3]:
!yolo train model=yolo12s.pt data='/kaggle/working/smokeandfire-2/data.yaml' epochs=20 imgsz=640 batch=32 augment=True 
Creating new Ultralytics Settings v0.0.6 file βœ… 
View Ultralytics Settings with 'yolo settings' or at '/root/.config/Ultralytics/settings.json'
Update Settings with 'yolo settings key=value', i.e. 'yolo settings runs_dir=path/to/dir'. For help see https://docs.ultralytics.com/quickstart/#ultralytics-settings.
Downloading https://github.com/ultralytics/assets/releases/download/v8.3.0/yolo12s.pt to 'yolo12s.pt'...
100%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| 18.1M/18.1M [00:01<00:00, 18.0MB/s]
Ultralytics 8.3.78 πŸš€ Python-3.10.14 torch-2.4.0 CUDA:0 (Tesla P100-PCIE-16GB, 16269MiB)
engine/trainer: task=detect, mode=train, model=yolo12s.pt, data=/kaggle/working/smokeandfire-2/data.yaml, epochs=20, time=None, patience=100, batch=32, imgsz=640, save=True, save_period=-1, cache=False, device=None, workers=8, project=None, name=train, exist_ok=False, pretrained=True, optimizer=auto, verbose=True, seed=0, deterministic=True, single_cls=False, rect=False, cos_lr=False, close_mosaic=10, resume=False, amp=True, fraction=1.0, profile=False, freeze=None, multi_scale=False, overlap_mask=True, mask_ratio=4, dropout=0.0, val=True, split=val, save_json=False, save_hybrid=False, conf=None, iou=0.7, max_det=300, half=False, dnn=False, plots=True, source=None, vid_stride=1, stream_buffer=False, visualize=False, augment=True, agnostic_nms=False, classes=None, retina_masks=False, embed=None, show=False, save_frames=False, save_txt=False, save_conf=False, save_crop=False, show_labels=True, show_conf=True, show_boxes=True, line_width=None, format=torchscript, keras=False, optimize=False, int8=False, dynamic=False, simplify=True, opset=None, workspace=None, nms=False, lr0=0.01, lrf=0.01, momentum=0.937, weight_decay=0.0005, warmup_epochs=3.0, warmup_momentum=0.8, warmup_bias_lr=0.1, box=7.5, cls=0.5, dfl=1.5, pose=12.0, kobj=1.0, nbs=64, hsv_h=0.015, hsv_s=0.7, hsv_v=0.4, degrees=0.0, translate=0.1, scale=0.5, shear=0.0, perspective=0.0, flipud=0.0, fliplr=0.5, bgr=0.0, mosaic=1.0, mixup=0.0, copy_paste=0.0, copy_paste_mode=flip, auto_augment=randaugment, erasing=0.4, crop_fraction=1.0, cfg=None, tracker=botsort.yaml, save_dir=runs/detect/train
Downloading https://ultralytics.com/assets/Arial.ttf to '/root/.config/Ultralytics/Arial.ttf'...
100%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| 755k/755k [00:00<00:00, 142MB/s]
Overriding model.yaml nc=80 with nc=2

                   from  n    params  module                                       arguments                     
  0                  -1  1       928  ultralytics.nn.modules.conv.Conv             [3, 32, 3, 2]                 
  1                  -1  1     18560  ultralytics.nn.modules.conv.Conv             [32, 64, 3, 2]                
  2                  -1  1     26080  ultralytics.nn.modules.block.C3k2            [64, 128, 1, False, 0.25]     
  3                  -1  1    147712  ultralytics.nn.modules.conv.Conv             [128, 128, 3, 2]              
  4                  -1  1    103360  ultralytics.nn.modules.block.C3k2            [128, 256, 1, False, 0.25]    
  5                  -1  1    590336  ultralytics.nn.modules.conv.Conv             [256, 256, 3, 2]              
  6                  -1  2    689408  ultralytics.nn.modules.block.A2C2f           [256, 256, 2, True, 4]        
  7                  -1  1   1180672  ultralytics.nn.modules.conv.Conv             [256, 512, 3, 2]              
  8                  -1  2   2689536  ultralytics.nn.modules.block.A2C2f           [512, 512, 2, True, 1]        
  9                  -1  1         0  torch.nn.modules.upsampling.Upsample         [None, 2, 'nearest']          
 10             [-1, 6]  1         0  ultralytics.nn.modules.conv.Concat           [1]                           
 11                  -1  1    345856  ultralytics.nn.modules.block.A2C2f           [768, 256, 1, False, -1]      
 12                  -1  1         0  torch.nn.modules.upsampling.Upsample         [None, 2, 'nearest']          
 13             [-1, 4]  1         0  ultralytics.nn.modules.conv.Concat           [1]                           
 14                  -1  1     95104  ultralytics.nn.modules.block.A2C2f           [512, 128, 1, False, -1]      
 15                  -1  1    147712  ultralytics.nn.modules.conv.Conv             [128, 128, 3, 2]              
 16            [-1, 11]  1         0  ultralytics.nn.modules.conv.Concat           [1]                           
 17                  -1  1    296704  ultralytics.nn.modules.block.A2C2f           [384, 256, 1, False, -1]      
 18                  -1  1    590336  ultralytics.nn.modules.conv.Conv             [256, 256, 3, 2]              
 19             [-1, 8]  1         0  ultralytics.nn.modules.conv.Concat           [1]                           
 20                  -1  1   1511424  ultralytics.nn.modules.block.C3k2            [768, 512, 1, True]           
 21        [14, 17, 20]  1    820182  ultralytics.nn.modules.head.Detect           [2, [128, 256, 512]]          
YOLOv12s summary: 272 layers, 9,253,910 parameters, 9,253,894 gradients, 21.5 GFLOPs

Transferred 685/691 items from pretrained weights
TensorBoard: Start with 'tensorboard --logdir runs/detect/train', view at http://localhost:6006/
Freezing layer 'model.21.dfl.conv.weight'
AMP: running Automatic Mixed Precision (AMP) checks...
Downloading https://github.com/ultralytics/assets/releases/download/v8.3.0/yolo11n.pt to 'yolo11n.pt'...
100%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| 5.35M/5.35M [00:00<00:00, 269MB/s]
AMP: checks passed βœ…
train: Scanning /kaggle/working/smokeandfire-2/train/labels... 8243 images, 11 b
train: New cache created: /kaggle/working/smokeandfire-2/train/labels.cache
WARNING ⚠️ Box and segment counts should be equal, but got len(segments) = 12, len(boxes) = 16365. To resolve this only boxes will be used and all segments will be removed. To avoid this please supply either a detect or segment dataset, not a detect-segment mixed dataset.
/opt/conda/lib/python3.10/site-packages/albumentations/__init__.py:24: UserWarning: A new version of Albumentations is available: 2.0.4 (you have 1.4.21). Upgrade using: pip install -U albumentations. To disable automatic update checks, set the environment variable NO_ALBUMENTATIONS_UPDATE to 1.
  check_for_updates()
albumentations: Blur(p=0.01, blur_limit=(3, 7)), MedianBlur(p=0.01, blur_limit=(3, 7)), ToGray(p=0.01, num_output_channels=3, method='weighted_average'), CLAHE(p=0.01, clip_limit=(1.0, 4.0), tile_grid_size=(8, 8))
/opt/conda/lib/python3.10/multiprocessing/popen_fork.py:66: RuntimeWarning: os.fork() was called. os.fork() is incompatible with multithreaded code, and JAX is multithreaded, so this will likely lead to a deadlock.
  self.pid = os.fork()
val: Scanning /kaggle/working/smokeandfire-2/valid/labels... 1062 images, 3 back
val: New cache created: /kaggle/working/smokeandfire-2/valid/labels.cache
/opt/conda/lib/python3.10/multiprocessing/popen_fork.py:66: RuntimeWarning: os.fork() was called. os.fork() is incompatible with multithreaded code, and JAX is multithreaded, so this will likely lead to a deadlock.
  self.pid = os.fork()
Plotting labels to runs/detect/train/labels.jpg... 
optimizer: 'optimizer=auto' found, ignoring 'lr0=0.01' and 'momentum=0.937' and determining best 'optimizer', 'lr0' and 'momentum' automatically... 
optimizer: AdamW(lr=0.001667, momentum=0.9) with parameter groups 113 weight(decay=0.0), 120 weight(decay=0.0005), 119 bias(decay=0.0)
TensorBoard: model graph visualization added βœ…
Image sizes 640 train, 640 val
Using 4 dataloader workers
Logging results to runs/detect/train
Starting training for 20 epochs...

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       1/20      12.4G      1.512      2.271      1.654        111        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.26      0.492      0.251      0.148

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       2/20        12G      1.532       1.74       1.67         68        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.791      0.667       0.72      0.508

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       3/20      12.3G      1.471      1.595      1.618         42        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.721      0.664       0.71      0.491

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       4/20        12G      1.417      1.517      1.582         67        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.831      0.648       0.72      0.529

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       5/20        12G      1.362      1.416      1.538         69        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.809      0.744      0.781       0.57

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       6/20        12G      1.329      1.358      1.515         65        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.849      0.796      0.814      0.607

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       7/20        12G      1.273       1.28      1.477         66        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.863      0.786      0.817      0.613

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       8/20        12G      1.252      1.241      1.462         54        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.865      0.799      0.826      0.623

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       9/20      12.1G      1.221       1.19      1.443         49        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.856       0.79      0.812      0.625

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      10/20      12.2G      1.226      1.187      1.452         79        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.828      0.795      0.809      0.616
Closing dataloader mosaic
albumentations: Blur(p=0.01, blur_limit=(3, 7)), MedianBlur(p=0.01, blur_limit=(3, 7)), ToGray(p=0.01, num_output_channels=3, method='weighted_average'), CLAHE(p=0.01, clip_limit=(1.0, 4.0), tile_grid_size=(8, 8))
/opt/conda/lib/python3.10/multiprocessing/popen_fork.py:66: RuntimeWarning: os.fork() was called. os.fork() is incompatible with multithreaded code, and JAX is multithreaded, so this will likely lead to a deadlock.
  self.pid = os.fork()

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      11/20        12G      1.261      1.134      1.493         41        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.862      0.814      0.831      0.641

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      12/20        12G      1.241      1.088      1.477         38        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.873      0.827      0.843       0.64

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      13/20        12G      1.224      1.063      1.461         34        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.878      0.834      0.845      0.666

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      14/20        12G      1.193      1.029      1.436         39        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.877       0.85      0.856      0.662

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      15/20        12G      1.165     0.9949      1.416         25        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.882      0.852      0.861      0.676

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      16/20        12G      1.152      0.955      1.406         35        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.866      0.849       0.85      0.667

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      17/20        12G      1.117      0.919      1.385         45        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.876      0.854      0.858      0.684

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      18/20        12G      1.095     0.8873      1.367         33        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.898      0.859      0.865      0.693

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      19/20        12G      1.076     0.8529      1.352         31        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.898       0.86      0.871      0.699

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      20/20        12G      1.048     0.8218      1.335         37        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.895      0.858       0.87      0.703

20 epochs completed in 1.573 hours.
Optimizer stripped from runs/detect/train/weights/last.pt, 18.9MB
Optimizer stripped from runs/detect/train/weights/best.pt, 18.9MB

Validating runs/detect/train/weights/best.pt...
Ultralytics 8.3.78 πŸš€ Python-3.10.14 torch-2.4.0 CUDA:0 (Tesla P100-PCIE-16GB, 16269MiB)
YOLOv12s summary (fused): 159 layers, 9,231,654 parameters, 0 gradients, 21.2 GFLOPs
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.878      0.858      0.866      0.696
                  Fire        859       1320      0.899      0.936      0.933      0.754
                 Smoke        559        761      0.856      0.779        0.8      0.639
Speed: 0.2ms preprocess, 15.5ms inference, 0.0ms loss, 0.8ms postprocess per image
Results saved to runs/detect/train
πŸ’‘ Learn more at https://docs.ultralytics.com/modes/train
InΒ [3]:
!yolo train model=yolo12s.pt data='/kaggle/working/smokeandfire-2/data.yaml' epochs=80 imgsz=640 batch=32 augment=True lr0=0.005 lrf=0.01 weight_decay=0.0005 optimizer=SGD mosaic=True hsv_h=0.015 hsv_s=0.7 hsv_v=0.4 degrees=15 translate=0.1 scale=0.5 shear=0.2 flipud=0.5 fliplr=0.5 mixup=0.2
Creating new Ultralytics Settings v0.0.6 file βœ… 
View Ultralytics Settings with 'yolo settings' or at '/root/.config/Ultralytics/settings.json'
Update Settings with 'yolo settings key=value', i.e. 'yolo settings runs_dir=path/to/dir'. For help see https://docs.ultralytics.com/quickstart/#ultralytics-settings.
Downloading https://github.com/ultralytics/assets/releases/download/v8.3.0/yolo12s.pt to 'yolo12s.pt'...
100%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| 18.1M/18.1M [00:00<00:00, 174MB/s]
Ultralytics 8.3.78 πŸš€ Python-3.10.14 torch-2.4.0 CUDA:0 (Tesla P100-PCIE-16GB, 16269MiB)
engine/trainer: task=detect, mode=train, model=yolo12s.pt, data=/kaggle/working/smokeandfire-2/data.yaml, epochs=80, time=None, patience=100, batch=32, imgsz=640, save=True, save_period=-1, cache=False, device=None, workers=8, project=None, name=train, exist_ok=False, pretrained=True, optimizer=SGD, verbose=True, seed=0, deterministic=True, single_cls=False, rect=False, cos_lr=False, close_mosaic=10, resume=False, amp=True, fraction=1.0, profile=False, freeze=None, multi_scale=False, overlap_mask=True, mask_ratio=4, dropout=0.0, val=True, split=val, save_json=False, save_hybrid=False, conf=None, iou=0.7, max_det=300, half=False, dnn=False, plots=True, source=None, vid_stride=1, stream_buffer=False, visualize=False, augment=True, agnostic_nms=False, classes=None, retina_masks=False, embed=None, show=False, save_frames=False, save_txt=False, save_conf=False, save_crop=False, show_labels=True, show_conf=True, show_boxes=True, line_width=None, format=torchscript, keras=False, optimize=False, int8=False, dynamic=False, simplify=True, opset=None, workspace=None, nms=False, lr0=0.005, lrf=0.01, momentum=0.937, weight_decay=0.0005, warmup_epochs=3.0, warmup_momentum=0.8, warmup_bias_lr=0.1, box=7.5, cls=0.5, dfl=1.5, pose=12.0, kobj=1.0, nbs=64, hsv_h=0.015, hsv_s=0.7, hsv_v=0.4, degrees=15, translate=0.1, scale=0.5, shear=0.2, perspective=0.0, flipud=0.5, fliplr=0.5, bgr=0.0, mosaic=True, mixup=0.2, copy_paste=0.0, copy_paste_mode=flip, auto_augment=randaugment, erasing=0.4, crop_fraction=1.0, cfg=None, tracker=botsort.yaml, save_dir=runs/detect/train
Downloading https://ultralytics.com/assets/Arial.ttf to '/root/.config/Ultralytics/Arial.ttf'...
100%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| 755k/755k [00:00<00:00, 16.9MB/s]
Overriding model.yaml nc=80 with nc=2

                   from  n    params  module                                       arguments                     
  0                  -1  1       928  ultralytics.nn.modules.conv.Conv             [3, 32, 3, 2]                 
  1                  -1  1     18560  ultralytics.nn.modules.conv.Conv             [32, 64, 3, 2]                
  2                  -1  1     26080  ultralytics.nn.modules.block.C3k2            [64, 128, 1, False, 0.25]     
  3                  -1  1    147712  ultralytics.nn.modules.conv.Conv             [128, 128, 3, 2]              
  4                  -1  1    103360  ultralytics.nn.modules.block.C3k2            [128, 256, 1, False, 0.25]    
  5                  -1  1    590336  ultralytics.nn.modules.conv.Conv             [256, 256, 3, 2]              
  6                  -1  2    689408  ultralytics.nn.modules.block.A2C2f           [256, 256, 2, True, 4]        
  7                  -1  1   1180672  ultralytics.nn.modules.conv.Conv             [256, 512, 3, 2]              
  8                  -1  2   2689536  ultralytics.nn.modules.block.A2C2f           [512, 512, 2, True, 1]        
  9                  -1  1         0  torch.nn.modules.upsampling.Upsample         [None, 2, 'nearest']          
 10             [-1, 6]  1         0  ultralytics.nn.modules.conv.Concat           [1]                           
 11                  -1  1    345856  ultralytics.nn.modules.block.A2C2f           [768, 256, 1, False, -1]      
 12                  -1  1         0  torch.nn.modules.upsampling.Upsample         [None, 2, 'nearest']          
 13             [-1, 4]  1         0  ultralytics.nn.modules.conv.Concat           [1]                           
 14                  -1  1     95104  ultralytics.nn.modules.block.A2C2f           [512, 128, 1, False, -1]      
 15                  -1  1    147712  ultralytics.nn.modules.conv.Conv             [128, 128, 3, 2]              
 16            [-1, 11]  1         0  ultralytics.nn.modules.conv.Concat           [1]                           
 17                  -1  1    296704  ultralytics.nn.modules.block.A2C2f           [384, 256, 1, False, -1]      
 18                  -1  1    590336  ultralytics.nn.modules.conv.Conv             [256, 256, 3, 2]              
 19             [-1, 8]  1         0  ultralytics.nn.modules.conv.Concat           [1]                           
 20                  -1  1   1511424  ultralytics.nn.modules.block.C3k2            [768, 512, 1, True]           
 21        [14, 17, 20]  1    820182  ultralytics.nn.modules.head.Detect           [2, [128, 256, 512]]          
YOLOv12s summary: 272 layers, 9,253,910 parameters, 9,253,894 gradients, 21.5 GFLOPs

Transferred 685/691 items from pretrained weights
TensorBoard: Start with 'tensorboard --logdir runs/detect/train', view at http://localhost:6006/
Freezing layer 'model.21.dfl.conv.weight'
AMP: running Automatic Mixed Precision (AMP) checks...
Downloading https://github.com/ultralytics/assets/releases/download/v8.3.0/yolo11n.pt to 'yolo11n.pt'...
100%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| 5.35M/5.35M [00:00<00:00, 72.9MB/s]
AMP: checks passed βœ…
train: Scanning /kaggle/working/smokeandfire-2/train/labels... 8243 images, 11 b
train: New cache created: /kaggle/working/smokeandfire-2/train/labels.cache
WARNING ⚠️ Box and segment counts should be equal, but got len(segments) = 12, len(boxes) = 16365. To resolve this only boxes will be used and all segments will be removed. To avoid this please supply either a detect or segment dataset, not a detect-segment mixed dataset.
/opt/conda/lib/python3.10/site-packages/albumentations/__init__.py:24: UserWarning: A new version of Albumentations is available: 2.0.4 (you have 1.4.21). Upgrade using: pip install -U albumentations. To disable automatic update checks, set the environment variable NO_ALBUMENTATIONS_UPDATE to 1.
  check_for_updates()
albumentations: Blur(p=0.01, blur_limit=(3, 7)), MedianBlur(p=0.01, blur_limit=(3, 7)), ToGray(p=0.01, num_output_channels=3, method='weighted_average'), CLAHE(p=0.01, clip_limit=(1.0, 4.0), tile_grid_size=(8, 8))
/opt/conda/lib/python3.10/multiprocessing/popen_fork.py:66: RuntimeWarning: os.fork() was called. os.fork() is incompatible with multithreaded code, and JAX is multithreaded, so this will likely lead to a deadlock.
  self.pid = os.fork()
val: Scanning /kaggle/working/smokeandfire-2/valid/labels... 1062 images, 3 back
val: New cache created: /kaggle/working/smokeandfire-2/valid/labels.cache
/opt/conda/lib/python3.10/multiprocessing/popen_fork.py:66: RuntimeWarning: os.fork() was called. os.fork() is incompatible with multithreaded code, and JAX is multithreaded, so this will likely lead to a deadlock.
  self.pid = os.fork()
Plotting labels to runs/detect/train/labels.jpg... 
optimizer: SGD(lr=0.005, momentum=0.937) with parameter groups 113 weight(decay=0.0), 120 weight(decay=0.0005), 119 bias(decay=0.0)
TensorBoard: model graph visualization added βœ…
Image sizes 640 train, 640 val
Using 4 dataloader workers
Logging results to runs/detect/train
Starting training for 80 epochs...

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       1/80      12.4G      1.606      2.359      1.799         96        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.823      0.738       0.77      0.541

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       2/80      12.2G       1.42      1.452      1.603         76        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.846      0.759      0.798      0.551

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       3/80      12.2G      1.473      1.497      1.645         53        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.814      0.686      0.721      0.497

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       4/80        12G      1.532      1.618      1.704         90        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.827      0.675      0.716      0.501

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       5/80        12G        1.5      1.554       1.68         95        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.834      0.753      0.794       0.56

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       6/80        12G      1.462      1.485      1.659         62        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.839      0.784      0.793      0.573

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       7/80        12G       1.43      1.452       1.63         72        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.845      0.753      0.789      0.562

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       8/80        12G      1.417      1.417      1.623         82        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.824      0.777      0.814      0.595

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       9/80        12G      1.386      1.388      1.601         54        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.852      0.804      0.823      0.606

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      10/80        12G      1.372      1.352      1.595         91        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.849      0.806      0.822      0.617

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      11/80        12G      1.351      1.324       1.57         88        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.857      0.817      0.831      0.621

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      12/80        12G      1.343      1.305      1.564        112        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.869      0.808      0.832      0.612

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      13/80      12.1G      1.338      1.293      1.558         76        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.854       0.81      0.828      0.613

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      14/80        12G      1.318      1.272      1.542         80        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.858      0.816      0.832      0.625

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      15/80        12G      1.314      1.268      1.547        114        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.868      0.837      0.845      0.637

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      16/80        12G      1.294       1.25      1.534         91        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.853      0.819      0.828      0.627

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      17/80        12G      1.285      1.233      1.528         65        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.867      0.827      0.835      0.632

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      18/80        12G      1.285      1.222      1.528        137        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.873      0.814      0.837      0.632

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      19/80        12G      1.279      1.211      1.524         92        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.865      0.832      0.841      0.637

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      20/80        12G      1.278      1.201      1.523         92        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.884      0.835      0.847      0.653

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      21/80        12G      1.255      1.163      1.498         75        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.885      0.847      0.852      0.642

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      22/80        12G       1.26      1.183      1.509         87        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.866      0.826      0.841       0.65

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      23/80        12G      1.243      1.159        1.5        117        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.883      0.839      0.856      0.654

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      24/80        12G      1.239      1.152      1.492        129        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.887      0.839      0.856      0.665

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      25/80        12G      1.237      1.124      1.481         80        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.886       0.85      0.864      0.668

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      26/80        12G       1.24      1.136      1.489         78        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.879      0.845      0.862      0.661

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      27/80        12G      1.213      1.114      1.467         75        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.895      0.852      0.867      0.675

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      28/80        12G      1.223      1.117      1.475         71        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.898       0.85      0.863       0.67

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      29/80        12G      1.215      1.101      1.472         71        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.893      0.853      0.868      0.672

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      30/80        12G      1.207      1.093       1.46         70        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.891      0.852       0.86      0.675

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      31/80        12G      1.192      1.072      1.451         68        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.887      0.852      0.863      0.671

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      32/80        12G      1.194      1.086      1.454         75        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.892      0.853      0.866      0.675

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      33/80        12G      1.194      1.066      1.451         97        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.895      0.849      0.871      0.682

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      34/80        12G      1.192      1.054      1.446         72        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.891      0.857      0.869      0.682

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      35/80        12G      1.176      1.058      1.443         72        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.895      0.849      0.866      0.684

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      36/80        12G      1.161      1.036       1.43        100        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.892      0.853      0.867      0.685

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      37/80        12G      1.172      1.033      1.431         81        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.898      0.853       0.87      0.688

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      38/80        12G      1.177      1.053      1.445         74        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081        0.9      0.859      0.872      0.693

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      39/80        12G       1.16      1.017      1.426         98        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.893      0.859      0.867       0.69

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      40/80        12G       1.15      0.999      1.414         77        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.902      0.856      0.872      0.691

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      41/80        12G       1.16      1.006      1.424         78        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081        0.9      0.861      0.866      0.696

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      42/80        12G      1.149      0.999      1.414        111        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.904      0.864      0.875      0.698

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      43/80        12G      1.153      1.005      1.412        111        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.903      0.855      0.872      0.697

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      44/80        12G      1.135     0.9739      1.412         67        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.908       0.86      0.875      0.695

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      45/80        12G      1.138     0.9789      1.412         79        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.898      0.866      0.877      0.697

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      46/80        12G      1.131     0.9579      1.399         94        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.901      0.861      0.874      0.697

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      47/80        12G      1.114     0.9625       1.39         77        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.908      0.861       0.88      0.703

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      48/80        12G      1.134     0.9643      1.402         57        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.902      0.864       0.88      0.706

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      49/80        12G      1.113     0.9482      1.391         96        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.902      0.864      0.877      0.704

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      50/80        12G      1.114     0.9463      1.396         91        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.903       0.86       0.88      0.709

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      51/80        12G      1.113     0.9379      1.387         76        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.906      0.861      0.884      0.708

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      52/80        12G      1.109     0.9318      1.383         99        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.89      0.863      0.878      0.706

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      53/80        12G      1.089     0.9139      1.363        103        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.911      0.863       0.88      0.708

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      54/80        12G       1.09     0.9126      1.366        100        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.897      0.863       0.88      0.711

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      55/80        12G      1.088     0.9111       1.37         78        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.91      0.858      0.881      0.714

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      56/80        12G      1.083     0.8995      1.367         68        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.909      0.863       0.88      0.714

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      57/80        12G      1.083     0.8901       1.36         76        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.908      0.864      0.883       0.71

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      58/80        12G      1.074     0.8867      1.356         61        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.911      0.864      0.881      0.713

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      59/80        12G      1.076      0.885      1.358        108        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.907      0.866      0.885      0.714

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      60/80        12G      1.087     0.9013      1.363        117        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.911      0.859      0.885      0.714

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      61/80        12G      1.066     0.8711      1.355         69        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.91      0.863       0.89      0.714

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      62/80        12G      1.069     0.8776      1.346         66        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.917      0.862      0.885      0.717

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      63/80        12G      1.053     0.8538      1.343         80        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.918      0.862      0.888      0.718

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      64/80        12G      1.053     0.8461      1.334         58        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.911      0.864      0.887      0.718

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      65/80        12G      1.045     0.8357      1.332         86        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.909      0.867      0.885      0.718

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      66/80        12G      1.046     0.8335      1.333        128        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.908      0.867      0.887       0.72

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      67/80        12G      1.025      0.818      1.319         53        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.916      0.865      0.887      0.717

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      68/80        12G      1.043     0.8391      1.333         97        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.907      0.864      0.885      0.719

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      69/80        12G       1.02      0.816      1.314         98        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.91      0.862      0.882      0.719

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      70/80        12G      1.026     0.8182      1.318         68        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.91      0.864      0.884       0.72
Closing dataloader mosaic
albumentations: Blur(p=0.01, blur_limit=(3, 7)), MedianBlur(p=0.01, blur_limit=(3, 7)), ToGray(p=0.01, num_output_channels=3, method='weighted_average'), CLAHE(p=0.01, clip_limit=(1.0, 4.0), tile_grid_size=(8, 8))
/opt/conda/lib/python3.10/multiprocessing/popen_fork.py:66: RuntimeWarning: os.fork() was called. os.fork() is incompatible with multithreaded code, and JAX is multithreaded, so this will likely lead to a deadlock.
  self.pid = os.fork()

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      71/80        12G     0.9291     0.6012      1.243         45        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.906      0.865      0.885      0.719

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      72/80      11.9G     0.9103     0.5719      1.231         34        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.903      0.867      0.887      0.721

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      73/80        12G     0.9051     0.5584       1.22         37        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.913      0.865      0.885      0.721

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      74/80      11.9G     0.8919     0.5476      1.215         39        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.909      0.864      0.885      0.722

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      75/80        12G     0.8817     0.5305      1.207         36        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.908      0.862      0.885      0.724

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      76/80        12G     0.8784     0.5278      1.199         33        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.91      0.862      0.885      0.725

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      77/80        12G     0.8746     0.5236      1.199         49        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.911      0.861      0.886      0.725

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      78/80        12G     0.8674     0.5103      1.195         43        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.913      0.864      0.885      0.724

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      79/80      11.9G     0.8655     0.5087      1.193         39        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.908      0.864      0.886      0.725

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      80/80        12G     0.8464     0.5037      1.179         49        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.91      0.862      0.887      0.725

80 epochs completed in 6.254 hours.
Optimizer stripped from runs/detect/train/weights/last.pt, 18.9MB
Optimizer stripped from runs/detect/train/weights/best.pt, 18.9MB

Validating runs/detect/train/weights/best.pt...
Ultralytics 8.3.78 πŸš€ Python-3.10.14 torch-2.4.0 CUDA:0 (Tesla P100-PCIE-16GB, 16269MiB)
YOLOv12s summary (fused): 159 layers, 9,231,654 parameters, 0 gradients, 21.2 GFLOPs
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.894      0.869      0.879      0.718
                  Fire        859       1320      0.913      0.939      0.931      0.766
                 Smoke        559        761      0.875        0.8      0.828      0.669
Speed: 0.2ms preprocess, 15.5ms inference, 0.0ms loss, 0.8ms postprocess per image
Results saved to runs/detect/train
πŸ’‘ Learn more at https://docs.ultralytics.com/modes/train
InΒ [4]:
import matplotlib.pyplot as plt
import matplotlib.image as mpimg

img = mpimg.imread('/kaggle/working/runs/detect/train/results.png')
imgplot = plt.imshow(img)
plt.show()
No description has been provided for this image
InΒ [5]:
img = mpimg.imread('/kaggle/working/runs/detect/train/confusion_matrix_normalized.png')
imgplot = plt.imshow(img)
plt.show()
No description has been provided for this image
InΒ [6]:
img = mpimg.imread('/kaggle/working/runs/detect/train/P_curve.png')
imgplot = plt.imshow(img)
plt.show()
No description has been provided for this image
InΒ [7]:
img = mpimg.imread('/kaggle/working/runs/detect/train/val_batch0_pred.jpg')
imgplot = plt.imshow(img)
plt.show()
No description has been provided for this image
InΒ [Β ]:
!yolo task=detect mode=predict model="/kaggle/working/runs/detect/train/weights/best.pt" device=0 source="/kaggle/working/smokeandfire-2/test/images" save=True
InΒ [9]:
from glob import glob
from PIL import Image
import numpy as np

img_path = glob('/kaggle/working/runs/detect/predict/*.jpg')
img_path = np.random.choice(img_path, 10)

for image_path in img_path:
    plt.imshow(Image.open(image_path))
    plt.axis("off")
    plt.show()
    print("\n")
No description has been provided for this image

No description has been provided for this image

No description has been provided for this image

No description has been provided for this image

No description has been provided for this image

No description has been provided for this image

No description has been provided for this image

No description has been provided for this image

No description has been provided for this image

No description has been provided for this image

InΒ [11]:
!yolo predict model="/kaggle/working/runs/detect/train/weights/best.pt", source="/kaggle/input/fireimage/fire.109.jpg"
WARNING ⚠️ argument 'model=/kaggle/working/runs/detect/train/weights/best.pt,' does not require trailing comma ',', updating to 'model=/kaggle/working/runs/detect/train/weights/best.pt'.
Ultralytics 8.3.78 πŸš€ Python-3.10.14 torch-2.4.0 CUDA:0 (Tesla P100-PCIE-16GB, 16269MiB)
YOLOv12s summary (fused): 159 layers, 9,231,654 parameters, 0 gradients, 21.2 GFLOPs

image 1/1 /kaggle/input/fireimage/fire.109.jpg: 384x640 6 Fires, 1 Smoke, 65.4ms
Speed: 6.0ms preprocess, 65.4ms inference, 160.2ms postprocess per image at shape (1, 3, 384, 640)
Results saved to runs/detect/predict2
πŸ’‘ Learn more at https://docs.ultralytics.com/modes/predict
InΒ [12]:
# Path to the output image
output_image_path = "/kaggle/working/runs/detect/predict2/fire.109.jpg"  # Adjust if the file name is different
output_image = cv2.imread(output_image_path)
output_image = cv2.cvtColor(output_image, cv2.COLOR_BGR2RGB)  # Convert BGR to RGB for correct display

# Display the output image
plt.figure(figsize=(8, 8))
plt.imshow(output_image)
plt.title('Detected Image - fire.109.jpg')
plt.axis('off') 
plt.show()
No description has been provided for this image
InΒ [15]:
!yolo predict model="/kaggle/working/runs/detect/train/weights/best.pt", source="/kaggle/input/fireeu/images.jpg"
WARNING ⚠️ argument 'model=/kaggle/working/runs/detect/train/weights/best.pt,' does not require trailing comma ',', updating to 'model=/kaggle/working/runs/detect/train/weights/best.pt'.
Ultralytics 8.3.78 πŸš€ Python-3.10.14 torch-2.4.0 CUDA:0 (Tesla P100-PCIE-16GB, 16269MiB)
YOLOv12s summary (fused): 159 layers, 9,231,654 parameters, 0 gradients, 21.2 GFLOPs

image 1/1 /kaggle/input/fireeu/images.jpg: 640x640 1 Fire, 2 Smokes, 14.9ms
Speed: 7.2ms preprocess, 14.9ms inference, 165.9ms postprocess per image at shape (1, 3, 640, 640)
Results saved to runs/detect/predict4
πŸ’‘ Learn more at https://docs.ultralytics.com/modes/predict
InΒ [16]:
import cv2
import matplotlib.pyplot as plt

# Path to the output image
output_image_path = "/kaggle/working/runs/detect/predict4/images.jpg"  # Adjust if the file name is different

# Load the output image
output_image = cv2.imread(output_image_path)
output_image = cv2.cvtColor(output_image, cv2.COLOR_BGR2RGB)  # Convert BGR to RGB for correct display

# Display the output image
plt.figure(figsize=(8, 8))
plt.imshow(output_image)
plt.title('Detected Image - fire.109.jpg')
plt.axis('off')  # Hide axes
plt.show()
No description has been provided for this image

yolo v8 small with 80 epochΒΆ

InΒ [17]:
!yolo train model=yolov8s.pt data='/kaggle/working/smokeandfire-2/data.yaml' epochs=80 imgsz=640 batch=32 augment=True lr0=0.005 lrf=0.01 weight_decay=0.0005 optimizer=SGD mosaic=True hsv_h=0.015 hsv_s=0.7 hsv_v=0.4 degrees=15 translate=0.1 scale=0.5 shear=0.2 flipud=0.5 fliplr=0.5 mixup=0.2
Downloading https://github.com/ultralytics/assets/releases/download/v8.3.0/yolov8s.pt to 'yolov8s.pt'...
100%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| 21.5M/21.5M [00:00<00:00, 42.8MB/s]
Ultralytics 8.3.78 πŸš€ Python-3.10.14 torch-2.4.0 CUDA:0 (Tesla P100-PCIE-16GB, 16269MiB)
engine/trainer: task=detect, mode=train, model=yolov8s.pt, data=/kaggle/working/smokeandfire-2/data.yaml, epochs=80, time=None, patience=100, batch=32, imgsz=640, save=True, save_period=-1, cache=False, device=None, workers=8, project=None, name=train2, exist_ok=False, pretrained=True, optimizer=SGD, verbose=True, seed=0, deterministic=True, single_cls=False, rect=False, cos_lr=False, close_mosaic=10, resume=False, amp=True, fraction=1.0, profile=False, freeze=None, multi_scale=False, overlap_mask=True, mask_ratio=4, dropout=0.0, val=True, split=val, save_json=False, save_hybrid=False, conf=None, iou=0.7, max_det=300, half=False, dnn=False, plots=True, source=None, vid_stride=1, stream_buffer=False, visualize=False, augment=True, agnostic_nms=False, classes=None, retina_masks=False, embed=None, show=False, save_frames=False, save_txt=False, save_conf=False, save_crop=False, show_labels=True, show_conf=True, show_boxes=True, line_width=None, format=torchscript, keras=False, optimize=False, int8=False, dynamic=False, simplify=True, opset=None, workspace=None, nms=False, lr0=0.005, lrf=0.01, momentum=0.937, weight_decay=0.0005, warmup_epochs=3.0, warmup_momentum=0.8, warmup_bias_lr=0.1, box=7.5, cls=0.5, dfl=1.5, pose=12.0, kobj=1.0, nbs=64, hsv_h=0.015, hsv_s=0.7, hsv_v=0.4, degrees=15, translate=0.1, scale=0.5, shear=0.2, perspective=0.0, flipud=0.5, fliplr=0.5, bgr=0.0, mosaic=True, mixup=0.2, copy_paste=0.0, copy_paste_mode=flip, auto_augment=randaugment, erasing=0.4, crop_fraction=1.0, cfg=None, tracker=botsort.yaml, save_dir=runs/detect/train2
Overriding model.yaml nc=80 with nc=2

                   from  n    params  module                                       arguments                     
  0                  -1  1       928  ultralytics.nn.modules.conv.Conv             [3, 32, 3, 2]                 
  1                  -1  1     18560  ultralytics.nn.modules.conv.Conv             [32, 64, 3, 2]                
  2                  -1  1     29056  ultralytics.nn.modules.block.C2f             [64, 64, 1, True]             
  3                  -1  1     73984  ultralytics.nn.modules.conv.Conv             [64, 128, 3, 2]               
  4                  -1  2    197632  ultralytics.nn.modules.block.C2f             [128, 128, 2, True]           
  5                  -1  1    295424  ultralytics.nn.modules.conv.Conv             [128, 256, 3, 2]              
  6                  -1  2    788480  ultralytics.nn.modules.block.C2f             [256, 256, 2, True]           
  7                  -1  1   1180672  ultralytics.nn.modules.conv.Conv             [256, 512, 3, 2]              
  8                  -1  1   1838080  ultralytics.nn.modules.block.C2f             [512, 512, 1, True]           
  9                  -1  1    656896  ultralytics.nn.modules.block.SPPF            [512, 512, 5]                 
 10                  -1  1         0  torch.nn.modules.upsampling.Upsample         [None, 2, 'nearest']          
 11             [-1, 6]  1         0  ultralytics.nn.modules.conv.Concat           [1]                           
 12                  -1  1    591360  ultralytics.nn.modules.block.C2f             [768, 256, 1]                 
 13                  -1  1         0  torch.nn.modules.upsampling.Upsample         [None, 2, 'nearest']          
 14             [-1, 4]  1         0  ultralytics.nn.modules.conv.Concat           [1]                           
 15                  -1  1    148224  ultralytics.nn.modules.block.C2f             [384, 128, 1]                 
 16                  -1  1    147712  ultralytics.nn.modules.conv.Conv             [128, 128, 3, 2]              
 17            [-1, 12]  1         0  ultralytics.nn.modules.conv.Concat           [1]                           
 18                  -1  1    493056  ultralytics.nn.modules.block.C2f             [384, 256, 1]                 
 19                  -1  1    590336  ultralytics.nn.modules.conv.Conv             [256, 256, 3, 2]              
 20             [-1, 9]  1         0  ultralytics.nn.modules.conv.Concat           [1]                           
 21                  -1  1   1969152  ultralytics.nn.modules.block.C2f             [768, 512, 1]                 
 22        [15, 18, 21]  1   2116822  ultralytics.nn.modules.head.Detect           [2, [128, 256, 512]]          
Model summary: 129 layers, 11,136,374 parameters, 11,136,358 gradients, 28.6 GFLOPs

Transferred 349/355 items from pretrained weights
TensorBoard: Start with 'tensorboard --logdir runs/detect/train2', view at http://localhost:6006/
Freezing layer 'model.22.dfl.conv.weight'
AMP: running Automatic Mixed Precision (AMP) checks...
AMP: checks passed βœ…
train: Scanning /kaggle/working/smokeandfire-2/train/labels.cache... 8243 images
WARNING ⚠️ Box and segment counts should be equal, but got len(segments) = 12, len(boxes) = 16365. To resolve this only boxes will be used and all segments will be removed. To avoid this please supply either a detect or segment dataset, not a detect-segment mixed dataset.
/opt/conda/lib/python3.10/site-packages/albumentations/__init__.py:24: UserWarning: A new version of Albumentations is available: 2.0.4 (you have 1.4.21). Upgrade using: pip install -U albumentations. To disable automatic update checks, set the environment variable NO_ALBUMENTATIONS_UPDATE to 1.
  check_for_updates()
albumentations: Blur(p=0.01, blur_limit=(3, 7)), MedianBlur(p=0.01, blur_limit=(3, 7)), ToGray(p=0.01, num_output_channels=3, method='weighted_average'), CLAHE(p=0.01, clip_limit=(1.0, 4.0), tile_grid_size=(8, 8))
/opt/conda/lib/python3.10/multiprocessing/popen_fork.py:66: RuntimeWarning: os.fork() was called. os.fork() is incompatible with multithreaded code, and JAX is multithreaded, so this will likely lead to a deadlock.
  self.pid = os.fork()
val: Scanning /kaggle/working/smokeandfire-2/valid/labels.cache... 1062 images, 
/opt/conda/lib/python3.10/multiprocessing/popen_fork.py:66: RuntimeWarning: os.fork() was called. os.fork() is incompatible with multithreaded code, and JAX is multithreaded, so this will likely lead to a deadlock.
  self.pid = os.fork()
Plotting labels to runs/detect/train2/labels.jpg... 
optimizer: SGD(lr=0.005, momentum=0.937) with parameter groups 57 weight(decay=0.0), 64 weight(decay=0.0005), 63 bias(decay=0.0)
TensorBoard: model graph visualization added βœ…
Image sizes 640 train, 640 val
Using 4 dataloader workers
Logging results to runs/detect/train2
Starting training for 80 epochs...

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       1/80      7.49G      1.777      2.502      1.856         96        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.68       0.54      0.589      0.424

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       2/80      7.68G      1.449      1.589      1.595         76        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.817      0.742      0.776      0.552

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       3/80      7.72G      1.443      1.496      1.573         53        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.794      0.726      0.759      0.537

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       4/80      7.72G      1.466      1.524      1.597         90        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.82      0.734      0.767      0.516

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       5/80      7.72G      1.449      1.478      1.577         95        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.824      0.751      0.792      0.576

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       6/80      7.79G      1.418       1.43      1.568         62        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.856      0.783      0.809       0.57

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       7/80       7.8G      1.397      1.393      1.543         72        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.862      0.783      0.813      0.573

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       8/80      7.71G      1.381      1.369      1.543         82        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.844      0.808      0.824      0.598

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       9/80      7.71G      1.361      1.349      1.527         54        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.857      0.779      0.811      0.597

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      10/80      7.71G      1.344      1.316      1.508         91        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.868      0.801      0.826      0.595

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      11/80      7.71G      1.327      1.293      1.498         88        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.869      0.806      0.829      0.608

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      12/80      7.73G      1.323      1.276      1.496        112        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.867      0.805       0.83      0.619

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      13/80      7.73G      1.314      1.262      1.485         76        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.857      0.795      0.791      0.585

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      14/80      7.71G      1.301      1.243       1.48         80        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.878      0.817      0.845      0.628

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      15/80      7.79G      1.297      1.242      1.476        114        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.877      0.814       0.84       0.63

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      16/80      7.79G      1.279      1.228      1.465         91        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.876      0.822      0.843      0.626

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      17/80      7.79G      1.269      1.212      1.465         65        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.876      0.835      0.852      0.638

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      18/80      7.79G      1.271      1.204      1.467        137        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.882      0.821       0.84      0.637

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      19/80      7.79G      1.267       1.19       1.46         92        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.864       0.83      0.842      0.629

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      20/80      7.71G      1.262      1.182      1.453         92        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.87      0.829      0.844      0.639

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      21/80      7.72G      1.241      1.152      1.433         75        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.886      0.847      0.849      0.644

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      22/80      7.79G      1.252      1.166      1.444         87        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.871      0.835      0.849      0.646

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      23/80      7.79G      1.231      1.145      1.435        117        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.892      0.843      0.863      0.658

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      24/80      7.79G      1.232      1.143       1.43        129        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.881      0.847      0.856      0.658

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      25/80      7.73G      1.224       1.12      1.416         80        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.895      0.836      0.857       0.66

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      26/80      7.73G      1.226      1.128      1.419         78        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.89      0.843      0.859      0.658

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      27/80      7.72G      1.206      1.103       1.41         75        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.882      0.847      0.861      0.663

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      28/80      7.79G      1.217      1.106      1.416         71        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.897      0.847      0.867      0.668

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      29/80      7.72G      1.206      1.099      1.407         71        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.884      0.849      0.861      0.667

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      30/80      7.79G        1.2      1.086      1.401         70        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.896      0.855      0.861      0.667

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      31/80      7.72G      1.186      1.069      1.388         68        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.897      0.838      0.856      0.672

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      32/80       7.8G      1.189      1.083      1.396         75        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081        0.9      0.852      0.857      0.665

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      33/80      7.81G      1.186      1.069      1.393         97        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.901      0.845       0.86       0.67

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      34/80      7.73G      1.188      1.055      1.389         72        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.902      0.849      0.858      0.674

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      35/80      7.79G      1.173      1.063      1.389         72        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.894      0.845      0.864      0.687

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      36/80       7.8G      1.152      1.028      1.366        100        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.888      0.851      0.858      0.673

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      37/80       7.8G      1.163      1.023      1.374         81        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.893      0.851      0.861      0.679

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      38/80      7.72G       1.17      1.042      1.383         74        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.896      0.844      0.862      0.677

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      39/80      7.73G      1.153      1.022      1.368         98        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.891      0.847      0.861      0.674

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      40/80      7.79G      1.144      1.009      1.361         77        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.899      0.841      0.858      0.679

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      41/80      7.72G      1.153      1.011      1.367         78        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.899       0.85      0.859       0.69

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      42/80      7.72G      1.141     0.9984      1.358        111        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.904      0.852      0.861      0.687

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      43/80      7.72G      1.148      1.001      1.352        111        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.891      0.857      0.857      0.685

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      44/80       7.8G      1.131     0.9783      1.351         67        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.898      0.854      0.868      0.691

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      45/80      7.72G      1.134     0.9825      1.356         79        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.904      0.854      0.868      0.692

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      46/80      7.72G      1.124     0.9722      1.342         94        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.896      0.855      0.871      0.697

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      47/80      7.72G      1.112     0.9707      1.334         77        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.899      0.864      0.872      0.698

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      48/80      7.72G      1.127     0.9679      1.342         57        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081        0.9       0.86      0.866      0.696

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      49/80      7.72G       1.11     0.9525      1.333         96        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.898      0.854      0.869      0.698

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      50/80      7.72G      1.109     0.9496      1.332         91        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.897       0.86      0.874      0.702

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      51/80      7.72G      1.106     0.9419      1.333         76        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.901      0.863      0.873      0.701

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      52/80      7.79G      1.109     0.9338      1.332         99        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.905      0.863       0.87        0.7

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      53/80       7.8G      1.084     0.9181      1.313        103        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.907      0.856       0.87      0.696

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      54/80      7.71G      1.087     0.9224      1.312        100        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.894      0.866      0.871      0.696

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      55/80       7.8G       1.09     0.9145      1.313         78        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.904      0.863      0.875      0.705

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      56/80      7.79G      1.078     0.9079       1.31         68        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.901      0.868      0.871      0.704

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      57/80       7.8G      1.078      0.905      1.308         76        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.903      0.863      0.877      0.707

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      58/80       7.8G      1.073     0.8991      1.307         61        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.898      0.867      0.871      0.703

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      59/80      7.72G      1.077     0.8967       1.31        108        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.905      0.865      0.873      0.703

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      60/80      7.72G      1.087     0.9122      1.313        117        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.914      0.865      0.875      0.703

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      61/80       7.8G      1.069     0.8888        1.3         69        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.912      0.864      0.877      0.708

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      62/80      7.71G      1.069     0.8887      1.293         66        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.903      0.869      0.875      0.708

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      63/80      7.72G      1.053     0.8714       1.29         80        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.907      0.866      0.873      0.706

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      64/80      7.71G      1.051     0.8612      1.282         58        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.909      0.868      0.875       0.71

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      65/80      7.72G      1.046     0.8514      1.275         86        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.91      0.867      0.875      0.712

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      66/80       7.8G      1.043     0.8504      1.282        128        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.907      0.872      0.877       0.71

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      67/80       7.8G      1.022     0.8309      1.267         53        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.908      0.865      0.875      0.709

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      68/80      7.79G      1.043     0.8582      1.286         97        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.905      0.862      0.873      0.707

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      69/80      7.72G      1.028     0.8307      1.271         98        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.908      0.865      0.871      0.708

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      70/80       7.8G      1.027     0.8349      1.271         68        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.906      0.864      0.872      0.706
Closing dataloader mosaic
albumentations: Blur(p=0.01, blur_limit=(3, 7)), MedianBlur(p=0.01, blur_limit=(3, 7)), ToGray(p=0.01, num_output_channels=3, method='weighted_average'), CLAHE(p=0.01, clip_limit=(1.0, 4.0), tile_grid_size=(8, 8))
/opt/conda/lib/python3.10/multiprocessing/popen_fork.py:66: RuntimeWarning: os.fork() was called. os.fork() is incompatible with multithreaded code, and JAX is multithreaded, so this will likely lead to a deadlock.
  self.pid = os.fork()

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      71/80      7.72G     0.9332     0.6394      1.202         45        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.911      0.855       0.87      0.705

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      72/80       7.8G     0.9181     0.6044      1.191         34        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.909      0.858      0.874      0.708

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      73/80      7.72G     0.9109       0.59      1.184         37        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.903      0.863      0.874      0.708

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      74/80      7.72G     0.8956     0.5777      1.175         39        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.909      0.857      0.874      0.711

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      75/80      7.72G     0.8891     0.5623      1.173         36        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.906      0.861      0.875      0.713

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      76/80      7.72G     0.8886     0.5596      1.168         33        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081        0.9      0.864      0.876      0.714

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      77/80      7.72G     0.8827     0.5559       1.16         49        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.903       0.86      0.874      0.714

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      78/80       7.8G     0.8754     0.5481      1.159         43        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.902      0.862      0.874      0.715

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      79/80      7.71G     0.8745     0.5433      1.157         39        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.902      0.863      0.874      0.714

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      80/80      7.72G     0.8573     0.5318      1.147         49        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.903      0.863      0.875      0.716

80 epochs completed in 3.188 hours.
Optimizer stripped from runs/detect/train2/weights/last.pt, 22.5MB
Optimizer stripped from runs/detect/train2/weights/best.pt, 22.5MB

Validating runs/detect/train2/weights/best.pt...
Ultralytics 8.3.78 πŸš€ Python-3.10.14 torch-2.4.0 CUDA:0 (Tesla P100-PCIE-16GB, 16269MiB)
Model summary (fused): 72 layers, 11,126,358 parameters, 0 gradients, 28.4 GFLOPs
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.895      0.866      0.878      0.712
                  Fire        859       1320      0.912       0.94      0.938      0.764
                 Smoke        559        761      0.879      0.791      0.819      0.661
Speed: 0.1ms preprocess, 10.0ms inference, 0.0ms loss, 0.8ms postprocess per image
Results saved to runs/detect/train2
πŸ’‘ Learn more at https://docs.ultralytics.com/modes/train

test our final model yolo v8ΒΆ

InΒ [9]:
!yolo val model=/kaggle/input/best/pytorch/default/1/bestt.pt data=/kaggle/working/smokeandfire-2/data.yaml split=train
Ultralytics 8.3.91 πŸš€ Python-3.10.14 torch-2.4.0 CUDA:0 (Tesla P100-PCIE-16GB, 16269MiB)
Model summary (fused): 72 layers, 11,126,358 parameters, 0 gradients, 28.4 GFLOPs
val: Scanning /kaggle/working/smokeandfire-2/train/labels... 8243 images, 11 bac
val: New cache created: /kaggle/working/smokeandfire-2/train/labels.cache
WARNING ⚠️ Box and segment counts should be equal, but got len(segments) = 12, len(boxes) = 16365. To resolve this only boxes will be used and all segments will be removed. To avoid this please supply either a detect or segment dataset, not a detect-segment mixed dataset.
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       8243      16365      0.925      0.876      0.935      0.709
                  Fire       6693      11239      0.928      0.898      0.944      0.709
                 Smoke       3785       5126      0.921      0.854      0.927      0.708
Speed: 0.2ms preprocess, 4.6ms inference, 0.0ms loss, 0.8ms postprocess per image
Results saved to runs/detect/val3
πŸ’‘ Learn more at https://docs.ultralytics.com/modes/val
InΒ [10]:
!yolo val model=/kaggle/input/best/pytorch/default/1/bestt.pt data=/kaggle/working/smokeandfire-2/data.yaml split=test
Ultralytics 8.3.91 πŸš€ Python-3.10.14 torch-2.4.0 CUDA:0 (Tesla P100-PCIE-16GB, 16269MiB)
Model summary (fused): 72 layers, 11,126,358 parameters, 0 gradients, 28.4 GFLOPs
val: Scanning /kaggle/working/smokeandfire-2/test/labels... 543 images, 1 backgr
val: New cache created: /kaggle/working/smokeandfire-2/test/labels.cache
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all        543       1065      0.943      0.881      0.902      0.788
                  Fire        528        748      0.965      0.951      0.963      0.819
                 Smoke        190        317      0.921      0.811      0.841      0.757
Speed: 0.5ms preprocess, 4.4ms inference, 0.0ms loss, 1.0ms postprocess per image
Results saved to runs/detect/val4
πŸ’‘ Learn more at https://docs.ultralytics.com/modes/val
InΒ [Β ]:
#pip install ultralytics==8.3.48
InΒ [Β ]:
#pip install torch==2.4.0 torchvision torchaudio

try to combine different sourcesΒΆ

InΒ [Β ]:
# merge
InΒ [Β ]:
!pip install roboflow

from roboflow import Roboflow
rf = Roboflow(api_key="GZBlBPlRdRvB6uR7BqaS")
project = rf.workspace("fire-and-smoke-detection").project("fds-p1vmt")
version = project.version(1)
dataset = version.download("yolov8")
                
InΒ [Β ]:
!pip install roboflow #Ψ―Ω‰

from roboflow import Roboflow
rf = Roboflow(api_key="GZBlBPlRdRvB6uR7BqaS")
project = rf.workspace("comsats-university-islamabad-wah-campus").project("smoke-detection-eopca")
version = project.version(1)
dataset = version.download("yolov8")
                
InΒ [Β ]:
!pip install roboflow 

from roboflow import Roboflow
rf = Roboflow(api_key="GZBlBPlRdRvB6uR7BqaS")
project = rf.workspace("smoke-detection").project("smoke100-uwe4t")
version = project.version(5)
dataset = version.download("yolov8")
                
InΒ [6]:
import os
import shutil 
import yaml
from glob import glob
import random

dataset1 = "/kaggle/working/FDS-1"
dataset2 = "/kaggle/working/smokeandfire-2"
dataset3 = "/kaggle/working/Smoke-Detection-1"
dataset4 = "/kaggle/working/smoke-upm-1"
dataset5 = "/kaggle/working/Smoke100-5"

output_dir = "/kaggle/working/combined_dataset_final6"

for split in ['train', 'valid', 'test']:
    for sub in ['images', 'labels']:
        os.makedirs(os.path.join(output_dir, split, sub), exist_ok=True)

def load_yaml(path):
    with open(path, 'r') as f:
        return yaml.safe_load(f)

data1 = load_yaml(os.path.join(dataset1, 'data.yaml'))
data2 = load_yaml(os.path.join(dataset2, 'data.yaml'))
data3 = load_yaml(os.path.join(dataset3, 'data.yaml'))

data1['names'] = [name.lower() for name in data1['names']]
data2['names'] = [name.lower() for name in data2['names']]
data3['names'] = [name.lower() for name in data3['names']]

combined_classes = sorted(set(data1['names'] + data2['names'] + data3['names'] + ['smoke']))  # ✨ Add smoke manually
name_to_index = {name: i for i, name in enumerate(combined_classes)}

# Helper to copy and update label 
def copy_dataset(src_root, split, src_data):
    img_dir = os.path.join(src_root, split, 'images')
    lbl_dir = os.path.join(src_root, split, 'labels')
    
    for img_path in glob(f"{img_dir}/*.jpg") + glob(f"{img_dir}/*.png"):
        base = os.path.splitext(os.path.basename(img_path))[0]
        label_path = os.path.join(lbl_dir, f"{base}.txt")
        
        # Copy image
        shutil.copy(img_path, os.path.join(output_dir, split, 'images'))

        if os.path.exists(label_path):
            with open(label_path, 'r') as f:
                lines = f.readlines()
            new_lines = []
            for line in lines:
                parts = line.strip().split()
                old_idx = int(parts[0])
                cls_name = src_data['names'][old_idx]
                new_idx = name_to_index[cls_name]
                new_line = " ".join([str(new_idx)] + parts[1:])
                new_lines.append(new_line)

            with open(os.path.join(output_dir, split, 'labels', f"{base}.txt"), 'w') as f:
                f.write("\n".join(new_lines))

# Helper to copy datasets 
def copy_smoke_dataset(src_root, split):
    img_dir = os.path.join(src_root, split, 'images')
    lbl_dir = os.path.join(src_root, split, 'labels')

    for img_path in glob(f"{img_dir}/*.jpg") + glob(f"{img_dir}/*.png"):
        base = os.path.splitext(os.path.basename(img_path))[0]
        label_path = os.path.join(lbl_dir, f"{base}.txt")

        # Copy image
        shutil.copy(img_path, os.path.join(output_dir, split, 'images'))

        if os.path.exists(label_path):
            with open(label_path, 'r') as f:
                lines = f.readlines()
            smoke_idx = name_to_index['smoke']
            new_lines = []
            for line in lines:
                parts = line.strip().split()
                new_line = " ".join([str(smoke_idx)] + parts[1:])
                new_lines.append(new_line)

            with open(os.path.join(output_dir, split, 'labels', f"{base}.txt"), 'w') as f:
                f.write("\n".join(new_lines))

def copy_limited_smoke_dataset(src_root, max_images=4200):
    img_dir = os.path.join(src_root, 'train', 'images')
    lbl_dir = os.path.join(src_root, 'train', 'labels')

    images = glob(f"{img_dir}/*.jpg") + glob(f"{img_dir}/*.png")
    images = random.sample(images, min(max_images, len(images)))  

    for img_path in images:
        base = os.path.splitext(os.path.basename(img_path))[0]
        label_path = os.path.join(lbl_dir, f"{base}.txt")

        # Copy image
        shutil.copy(img_path, os.path.join(output_dir, 'train', 'images'))

        if os.path.exists(label_path):
            with open(label_path, 'r') as f:
                lines = f.readlines()
            smoke_idx = name_to_index['smoke']
            new_lines = []
            for line in lines:
                parts = line.strip().split()
                new_line = " ".join([str(smoke_idx)] + parts[1:])
                new_lines.append(new_line)

            with open(os.path.join(output_dir, 'train', 'labels', f"{base}.txt"), 'w') as f:
                f.write("\n".join(new_lines))

for split in ['train', 'valid', 'test']:
    copy_dataset(dataset1, split, data1)
    copy_dataset(dataset2, split, data2)
    copy_dataset(dataset3, split, data3)
    copy_smoke_dataset(dataset4, split)

copy_limited_smoke_dataset(dataset5, max_images=4200)

new_yaml = {
    'train': os.path.join(output_dir, 'train', 'images'),
    'val': os.path.join(output_dir, 'valid', 'images'),
    'test': os.path.join(output_dir, 'test', 'images'),
    'nc': len(combined_classes),
    'names': combined_classes
}

with open(os.path.join(output_dir, 'data.yaml'), 'w') as f:
    yaml.dump(new_yaml, f)

print(" merged")
 merged
InΒ [7]:
from collections import defaultdict 
splits = ['train', 'valid', 'test']
labels_root = "/kaggle/working/combined_dataset_final6"  
class_names = combined_classes  
for split in splits:
    class_counts = defaultdict(int)
    label_files = glob(os.path.join(labels_root, split, 'labels', '*.txt'))
    
    for label_file in label_files:
        with open(label_file, 'r') as f:
            lines = f.readlines()
        
        for line in lines:
            cls_id = int(line.strip().split()[0])
            class_counts[cls_id] += 1
    
    print(f"\n Split: {split.upper()}")
    total_labels = 0
    for cls_id, count in class_counts.items():
        print(f"  - {class_names[cls_id]}: {count} images")
        total_labels += count
    print(f" Total labels in {split}: {total_labels}")
 Split: TRAIN
  - smoke: 15483 images
  - fire: 16051 images
 Total labels in train: 31534

 Split: VALID
  - fire: 2708 images
  - smoke: 2566 images
 Total labels in valid: 5274

 Split: TEST
  - fire: 1341 images
  - smoke: 1104 images
 Total labels in test: 2445
InΒ [8]:
!yolo train model=yolov8s.pt data='/kaggle/working/combined_dataset_final6/data.yaml' epochs=80 imgsz=640 batch=32 augment=True lr0=0.005 lrf=0.01 weight_decay=0.0005 optimizer=SGD mosaic=True hsv_h=0.015 hsv_s=0.7 hsv_v=0.4 degrees=15 translate=0.1 scale=0.5 shear=0.2 flipud=0.5 fliplr=0.5 mixup=0.2
Downloading https://github.com/ultralytics/assets/releases/download/v8.3.0/yolov8s.pt to 'yolov8s.pt'...
100%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| 21.5M/21.5M [00:00<00:00, 331MB/s]
Ultralytics 8.3.126 πŸš€ Python-3.10.14 torch-2.4.0 CUDA:0 (Tesla P100-PCIE-16GB, 16269MiB)
engine/trainer: agnostic_nms=False, amp=True, augment=True, auto_augment=randaugment, batch=32, bgr=0.0, box=7.5, cache=False, cfg=None, classes=None, close_mosaic=10, cls=0.5, conf=None, copy_paste=0.0, copy_paste_mode=flip, cos_lr=False, cutmix=0.0, data=/kaggle/working/combined_dataset_final6/data.yaml, degrees=15, deterministic=True, device=cuda:0, dfl=1.5, dnn=False, dropout=0.0, dynamic=False, embed=None, epochs=80, erasing=0.4, exist_ok=False, fliplr=0.5, flipud=0.5, format=torchscript, fraction=1.0, freeze=None, half=False, hsv_h=0.015, hsv_s=0.7, hsv_v=0.4, imgsz=640, int8=False, iou=0.7, keras=False, kobj=1.0, line_width=None, lr0=0.005, lrf=0.01, mask_ratio=4, max_det=300, mixup=0.2, mode=train, model=yolov8s.pt, momentum=0.937, mosaic=True, multi_scale=False, name=train, nbs=64, nms=False, opset=None, optimize=False, optimizer=SGD, overlap_mask=True, patience=100, perspective=0.0, plots=True, pose=12.0, pretrained=True, profile=False, project=None, rect=False, resume=False, retina_masks=False, save=True, save_conf=False, save_crop=False, save_dir=runs/detect/train, save_frames=False, save_json=False, save_period=-1, save_txt=False, scale=0.5, seed=0, shear=0.2, show=False, show_boxes=True, show_conf=True, show_labels=True, simplify=True, single_cls=False, source=None, split=val, stream_buffer=False, task=detect, time=None, tracker=botsort.yaml, translate=0.1, val=True, verbose=True, vid_stride=1, visualize=False, warmup_bias_lr=0.1, warmup_epochs=3.0, warmup_momentum=0.8, weight_decay=0.0005, workers=8, workspace=None
Downloading https://ultralytics.com/assets/Arial.ttf to '/root/.config/Ultralytics/Arial.ttf'...
100%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| 755k/755k [00:00<00:00, 42.7MB/s]
Overriding model.yaml nc=80 with nc=2

                   from  n    params  module                                       arguments                     
  0                  -1  1       928  ultralytics.nn.modules.conv.Conv             [3, 32, 3, 2]                 
  1                  -1  1     18560  ultralytics.nn.modules.conv.Conv             [32, 64, 3, 2]                
  2                  -1  1     29056  ultralytics.nn.modules.block.C2f             [64, 64, 1, True]             
  3                  -1  1     73984  ultralytics.nn.modules.conv.Conv             [64, 128, 3, 2]               
  4                  -1  2    197632  ultralytics.nn.modules.block.C2f             [128, 128, 2, True]           
  5                  -1  1    295424  ultralytics.nn.modules.conv.Conv             [128, 256, 3, 2]              
  6                  -1  2    788480  ultralytics.nn.modules.block.C2f             [256, 256, 2, True]           
  7                  -1  1   1180672  ultralytics.nn.modules.conv.Conv             [256, 512, 3, 2]              
  8                  -1  1   1838080  ultralytics.nn.modules.block.C2f             [512, 512, 1, True]           
  9                  -1  1    656896  ultralytics.nn.modules.block.SPPF            [512, 512, 5]                 
 10                  -1  1         0  torch.nn.modules.upsampling.Upsample         [None, 2, 'nearest']          
 11             [-1, 6]  1         0  ultralytics.nn.modules.conv.Concat           [1]                           
 12                  -1  1    591360  ultralytics.nn.modules.block.C2f             [768, 256, 1]                 
 13                  -1  1         0  torch.nn.modules.upsampling.Upsample         [None, 2, 'nearest']          
 14             [-1, 4]  1         0  ultralytics.nn.modules.conv.Concat           [1]                           
 15                  -1  1    148224  ultralytics.nn.modules.block.C2f             [384, 128, 1]                 
 16                  -1  1    147712  ultralytics.nn.modules.conv.Conv             [128, 128, 3, 2]              
 17            [-1, 12]  1         0  ultralytics.nn.modules.conv.Concat           [1]                           
 18                  -1  1    493056  ultralytics.nn.modules.block.C2f             [384, 256, 1]                 
 19                  -1  1    590336  ultralytics.nn.modules.conv.Conv             [256, 256, 3, 2]              
 20             [-1, 9]  1         0  ultralytics.nn.modules.conv.Concat           [1]                           
 21                  -1  1   1969152  ultralytics.nn.modules.block.C2f             [768, 512, 1]                 
 22        [15, 18, 21]  1   2116822  ultralytics.nn.modules.head.Detect           [2, [128, 256, 512]]          
Model summary: 129 layers, 11,136,374 parameters, 11,136,358 gradients, 28.6 GFLOPs

Transferred 349/355 items from pretrained weights
Freezing layer 'model.22.dfl.conv.weight'
AMP: running Automatic Mixed Precision (AMP) checks...
Downloading https://github.com/ultralytics/assets/releases/download/v8.3.0/yolo11n.pt to 'yolo11n.pt'...
100%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| 5.35M/5.35M [00:00<00:00, 198MB/s]
AMP: checks passed βœ…
train: Fast image access βœ… (ping: 0.0Β±0.0 ms, read: 780.5Β±596.0 MB/s, size: 23.4 KB)
train: Scanning /kaggle/working/combined_dataset_final6/train/labels... 21725 im
train: New cache created: /kaggle/working/combined_dataset_final6/train/labels.cache
WARNING ⚠️ Box and segment counts should be equal, but got len(segments) = 22, len(boxes) = 31534. To resolve this only boxes will be used and all segments will be removed. To avoid this please supply either a detect or segment dataset, not a detect-segment mixed dataset.
albumentations: Blur(p=0.01, blur_limit=(3, 7)), MedianBlur(p=0.01, blur_limit=(3, 7)), ToGray(p=0.01, num_output_channels=3, method='weighted_average'), CLAHE(p=0.01, clip_limit=(1.0, 4.0), tile_grid_size=(8, 8))
val: Fast image access βœ… (ping: 0.0Β±0.0 ms, read: 631.9Β±180.0 MB/s, size: 35.9 KB)
val: Scanning /kaggle/working/combined_dataset_final6/valid/labels... 3718 image
val: New cache created: /kaggle/working/combined_dataset_final6/valid/labels.cache
Plotting labels to runs/detect/train/labels.jpg... 
optimizer: SGD(lr=0.005, momentum=0.937) with parameter groups 57 weight(decay=0.0), 64 weight(decay=0.0005), 63 bias(decay=0.0)
Image sizes 640 train, 640 val
Using 4 dataloader workers
Logging results to runs/detect/train
Starting training for 80 epochs...

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       1/80      7.62G      1.789      2.306      1.899        123        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.689      0.575      0.605      0.327

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       2/80      7.64G      1.504      1.489      1.639         98        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274       0.82      0.747      0.806      0.447

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       3/80      7.65G      1.489      1.452      1.629        115        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.734      0.672      0.712       0.38

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       4/80      7.65G      1.522       1.48       1.65        114        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.763      0.738      0.778      0.436

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       5/80      7.65G      1.481      1.406      1.615        104        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.802      0.778       0.81      0.463

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       6/80      7.65G      1.444      1.347      1.594        105        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.831        0.8      0.839      0.498

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       7/80      7.65G      1.407      1.289      1.567         92        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.846      0.815      0.843      0.518

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       8/80      7.65G      1.407      1.281      1.567         92        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.852      0.827      0.859      0.523

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
       9/80      7.65G      1.386      1.243      1.546        106        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.854      0.839      0.868      0.528

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      10/80      7.65G      1.368      1.217      1.535        109        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.874      0.845      0.876      0.536

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      11/80      7.65G      1.355      1.197      1.524         87        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.883      0.848      0.882      0.545

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      12/80      7.65G       1.34      1.173      1.509         89        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.889      0.854      0.887      0.556

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      13/80      7.65G      1.335      1.161      1.508        115        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.882      0.859      0.886       0.57

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      14/80      7.65G      1.314      1.134      1.491         93        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.889      0.865      0.894      0.567

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      15/80      7.65G      1.309      1.129      1.486        117        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.893      0.867      0.895      0.575

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      16/80      7.65G      1.296      1.113      1.477        111        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.893      0.866      0.896      0.585

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      17/80      7.65G      1.296        1.1      1.474         93        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.894      0.867      0.896      0.579

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      18/80      7.65G      1.291      1.093      1.466         95        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.894      0.877      0.904      0.596

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      19/80      7.65G      1.281      1.077      1.461         94        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.903      0.881      0.903      0.593

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      20/80      7.65G      1.269      1.072      1.456        116        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.906      0.883      0.905      0.599

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      21/80      7.65G      1.263       1.06      1.452        109        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.904      0.886       0.91      0.606

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      22/80      7.65G      1.264      1.054      1.449        110        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.899      0.888      0.907      0.604

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      23/80      7.65G       1.26      1.049      1.442        110        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.912      0.883      0.909      0.609

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      24/80      7.65G       1.24      1.027      1.431         80        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.921      0.883      0.914      0.617

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      25/80      7.65G      1.239       1.02      1.431         85        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.916      0.888      0.913      0.616

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      26/80      7.65G      1.235      1.015      1.427        117        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.916      0.889      0.912       0.62

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      27/80      7.65G      1.234      1.013      1.428         89        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.919      0.888      0.917      0.624

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      28/80      7.65G      1.223      1.001      1.416         97        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.922      0.892      0.915      0.625

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      29/80      7.65G      1.221     0.9965      1.418         88        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.922       0.89      0.918       0.63

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      30/80      7.65G      1.215     0.9863      1.411         95        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.927      0.891      0.919      0.632

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      31/80      7.65G      1.208     0.9772      1.403        106        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.923       0.89      0.917       0.63

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      32/80      7.65G      1.209      0.972      1.408         80        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.917      0.892      0.916      0.634

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      33/80      7.65G      1.199     0.9618      1.398         97        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274       0.92      0.891      0.917      0.636

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      34/80      7.65G      1.202     0.9712      1.402         99        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.922      0.894      0.917      0.639

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      35/80      7.65G      1.192     0.9521      1.398        119        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.921      0.896      0.919      0.641

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      36/80      7.65G      1.187      0.947      1.392        133        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274       0.92      0.895       0.92      0.642

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      37/80      7.65G      1.186     0.9395      1.386         82        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.921      0.894      0.919      0.641

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      38/80      7.65G      1.177     0.9359      1.384         83        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.922      0.891      0.918      0.644

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      39/80      7.65G      1.175     0.9357      1.385        116        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.922      0.893      0.918      0.646

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      40/80      7.65G      1.173     0.9277      1.383         98        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.921      0.895      0.919      0.648

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      41/80      7.65G      1.169      0.919      1.376         98        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.925      0.891      0.919      0.648

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      42/80      7.65G       1.16     0.9141      1.369         89        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.928      0.894       0.92      0.649

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      43/80      7.65G      1.164     0.9189      1.375         92        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.923      0.898      0.921      0.651

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      44/80      7.65G      1.154     0.9057      1.362         91        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.926      0.897      0.922      0.651

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      45/80      7.65G      1.147     0.8937      1.357        106        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.925        0.9      0.922      0.653

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      46/80      7.65G      1.147     0.8967      1.357        115        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.924        0.9      0.922      0.654

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      47/80      7.65G      1.146     0.8927      1.356        117        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.925      0.899      0.922      0.654

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      48/80      7.65G      1.136     0.8756      1.352        111        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.926        0.9      0.923      0.654

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      49/80      7.65G      1.137     0.8812       1.35         81        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.926        0.9      0.923      0.656

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      50/80      7.65G      1.139     0.8849      1.354         90        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.927      0.898      0.923      0.656

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      51/80      7.65G      1.127      0.875      1.346         79        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.923        0.9      0.923      0.656

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      52/80      7.65G      1.123     0.8545      1.337         93        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.925      0.899      0.923      0.657

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      53/80      7.65G      1.118     0.8563      1.337         96        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.927      0.897      0.923      0.657

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      54/80      7.65G      1.112     0.8555      1.339         91        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.924      0.903      0.923      0.658

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      55/80      7.65G       1.12     0.8603      1.341         91        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.927        0.9      0.923      0.658

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      56/80      7.65G      1.106     0.8399      1.334        107        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.927        0.9      0.923      0.658

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      57/80      7.65G      1.113     0.8484      1.336         92        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.926      0.902      0.923      0.659

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      58/80      7.65G      1.098     0.8355      1.323        121        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.925      0.903      0.924      0.659

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      59/80      7.65G      1.103     0.8363      1.326         98        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.926      0.903      0.924       0.66

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      60/80      7.65G      1.094     0.8231      1.318        133        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.927      0.903      0.924       0.66

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      61/80      7.65G      1.088     0.8159      1.312        111        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.927      0.904      0.925      0.661

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      62/80      7.65G      1.088     0.8158      1.314         95        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.927      0.904      0.924      0.661

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      63/80      7.65G      1.086     0.8115      1.312        114        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.928      0.905      0.926      0.661

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      64/80      7.65G       1.08     0.8129      1.312         90        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.928      0.905      0.926      0.662

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      65/80      7.65G      1.082     0.8094      1.313         85        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.927      0.906      0.926      0.662

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      66/80      7.65G      1.077     0.8019      1.303        125        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.929      0.906      0.927      0.662

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      67/80      7.65G      1.072      0.789      1.298        123        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.929      0.906      0.927      0.662

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      68/80      7.65G      1.069      0.792      1.298        110        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.931      0.904      0.927      0.663

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      69/80      7.65G      1.063     0.7877      1.298         94        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.931      0.905      0.927      0.663

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      70/80      7.65G      1.057     0.7794      1.295         99        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.932      0.907      0.928      0.664
Closing dataloader mosaic
albumentations: Blur(p=0.01, blur_limit=(3, 7)), MedianBlur(p=0.01, blur_limit=(3, 7)), ToGray(p=0.01, num_output_channels=3, method='weighted_average'), CLAHE(p=0.01, clip_limit=(1.0, 4.0), tile_grid_size=(8, 8))

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      71/80      7.65G     0.9323     0.5644      1.212         48        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.931      0.908      0.928      0.664

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      72/80      7.65G      0.917     0.5446      1.198         36        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.931      0.908      0.928      0.664

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      73/80      7.65G     0.9057     0.5325      1.189         30        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.931      0.909      0.929      0.664

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      74/80      7.65G     0.9025     0.5259      1.192         42        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.931      0.909      0.928      0.665

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      75/80      7.65G     0.8977     0.5201      1.189         38        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274       0.93       0.91      0.928      0.665

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      76/80      7.65G     0.8858     0.5093      1.177         42        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.932      0.909      0.928      0.666

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      77/80      7.65G     0.8829     0.5046       1.18         41        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.932      0.908      0.929      0.666

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      78/80      7.65G     0.8735     0.5023      1.175         46        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.933      0.909      0.929      0.666

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      79/80      7.65G     0.8693      0.496      1.167         43        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.933      0.909      0.929      0.667

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      80/80      7.65G     0.8675     0.4929      1.166         34        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.932      0.909      0.929      0.667

80 epochs completed in 8.459 hours.
Optimizer stripped from runs/detect/train/weights/last.pt, 22.5MB
Optimizer stripped from runs/detect/train/weights/best.pt, 22.5MB

Validating runs/detect/train/weights/best.pt...
Ultralytics 8.3.126 πŸš€ Python-3.10.14 torch-2.4.0 CUDA:0 (Tesla P100-PCIE-16GB, 16269MiB)
Model summary (fused): 72 layers, 11,126,358 parameters, 0 gradients, 28.4 GFLOPs
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       3718       5274      0.927      0.902      0.928      0.665
                  fire       1859       2708      0.925      0.915      0.941      0.668
                 smoke       2268       2566      0.929      0.889      0.914      0.662
Speed: 0.1ms preprocess, 9.0ms inference, 0.0ms loss, 0.8ms postprocess per image
Results saved to runs/detect/train
πŸ’‘ Learn more at https://docs.ultralytics.com/modes/train
InΒ [Β ]:
!yolo task=detect mode=predict model="/kaggle/working/runs/detect/train/weights/best.pt" device=0 source="/kaggle/working/combined_dataset_final6/test/images" save=True
InΒ [11]:
from ultralytics import YOLO
model = YOLO("/kaggle/working/runs/detect/train/weights/best.pt")  


# Evaluate on Training Data
train_results = model.val(data="/kaggle/working/combined_dataset_final6/data.yaml", split="train")
print(f"Train mAP@50: {train_results.box.map50:.4f}")
print(f"Train mAP@50-95: {train_results.box.map:.4f}")
Ultralytics 8.3.126 πŸš€ Python-3.10.14 torch-2.4.0 CUDA:0 (Tesla P100-PCIE-16GB, 16269MiB)
Model summary (fused): 72 layers, 11,126,358 parameters, 0 gradients, 28.4 GFLOPs
val: Fast image access βœ… (ping: 0.0Β±0.0 ms, read: 747.7Β±473.2 MB/s, size: 27.0 KB)
val: Scanning /kaggle/working/combined_dataset_final6/train/labels.cache... 21725 images, 1204 backgrounds, 0 corrupt: 100%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| 21725/21725 [00:00<?, ?it/s]
WARNING ⚠️ Box and segment counts should be equal, but got len(segments) = 22, len(boxes) = 31534. To resolve this only boxes will be used and all segments will be removed. To avoid this please supply either a detect or segment dataset, not a detect-segment mixed dataset.
                 Class     Images  Instances      Box(P          R      mAP50  mAP50-95): 100%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| 1358/1358 [02:45<00:00,  8.19it/s]
                   all      21725      31534       0.93      0.868      0.934      0.689
                  fire      10026      16051      0.909       0.85      0.918      0.641
                 smoke      13622      15483      0.951      0.887       0.95      0.737
Speed: 0.2ms preprocess, 4.3ms inference, 0.0ms loss, 0.9ms postprocess per image
Results saved to runs/detect/val3
Train mAP@50: 0.9336
Train mAP@50-95: 0.6891
InΒ [13]:
# Evaluate on Test Data
test_results = model.val(data="/kaggle/working/combined_dataset_final6/data.yaml", split="test")
print(f"Test mAP@50: {test_results.box.map50:.4f}")
print(f"Test mAP@50-95: {test_results.box.map:.4f}")
Ultralytics 8.3.126 πŸš€ Python-3.10.14 torch-2.4.0 CUDA:0 (Tesla P100-PCIE-16GB, 16269MiB)
val: Fast image access βœ… (ping: 0.0Β±0.0 ms, read: 522.9Β±333.5 MB/s, size: 25.5 KB)
val: Scanning /kaggle/working/smokeandfire-2/test/labels... 543 images, 1 backgrounds, 0 corrupt: 100%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| 543/543 [00:00<00:00, 1208.44it/s]
val: New cache created: /kaggle/working/smokeandfire-2/test/labels.cache
                 Class     Images  Instances      Box(P          R      mAP50  mAP50-95): 100%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| 34/34 [00:05<00:00,  6.35it/s]
                   all        543       1065      0.942      0.883      0.896      0.775
                  fire        528        748      0.959      0.959      0.962      0.807
                 smoke        190        317      0.926      0.808       0.83      0.744
Speed: 0.6ms preprocess, 4.4ms inference, 0.0ms loss, 1.3ms postprocess per image
Results saved to runs/detect/val5
Test mAP@50: 0.8961
Test mAP@50-95: 0.7755
InΒ [14]:
import matplotlib.pyplot as plt
import matplotlib.image as mpimg

img = mpimg.imread('/kaggle/working/runs/detect/train/results.png')
imgplot = plt.imshow(img)
plt.show()
No description has been provided for this image
InΒ [24]:
img = mpimg.imread('/kaggle/working/runs/detect/train/P_curve.png')
imgplot = plt.imshow(img)
plt.show()
No description has been provided for this image
InΒ [16]:
import matplotlib.pyplot as plt
import matplotlib.image as mpimg

img = mpimg.imread('/kaggle/working/runs/detect/train/labels.jpg')
imgplot = plt.imshow(img)
plt.show()
No description has been provided for this image
InΒ [17]:
import matplotlib.pyplot as plt
import matplotlib.image as mpimg

img = mpimg.imread('/kaggle/working/runs/detect/train/confusion_matrix.png')
imgplot = plt.imshow(img)
plt.show()
No description has been provided for this image
InΒ [18]:
import matplotlib.pyplot as plt
import matplotlib.image as mpimg

img = mpimg.imread('/kaggle/working/runs/detect/train/train_batch0.jpg')
imgplot = plt.imshow(img)
plt.show()
No description has been provided for this image
InΒ [19]:
from glob import glob
from PIL import Image
import numpy as np

img_path = glob('/kaggle/working/runs/detect/predict/*.jpg')
img_path = np.random.choice(img_path, 10)

for image_path in img_path:
    plt.imshow(Image.open(image_path))
    plt.axis("off")
    plt.show()
    print("\n")
No description has been provided for this image

No description has been provided for this image

No description has been provided for this image

No description has been provided for this image

No description has been provided for this image

No description has been provided for this image

No description has been provided for this image

No description has been provided for this image

No description has been provided for this image

No description has been provided for this image

InΒ [20]:
!yolo predict model="/kaggle/working/runs/detect/train/weights/best.pt", source="/kaggle/input/fireeee/fire.109.jpg"
WARNING ⚠️ argument 'model=/kaggle/working/runs/detect/train/weights/best.pt,' does not require trailing comma ',', updating to 'model=/kaggle/working/runs/detect/train/weights/best.pt'.
Ultralytics 8.3.126 πŸš€ Python-3.10.14 torch-2.4.0 CUDA:0 (Tesla P100-PCIE-16GB, 16269MiB)
Model summary (fused): 72 layers, 11,126,358 parameters, 0 gradients, 28.4 GFLOPs

image 1/1 /kaggle/input/fireeee/fire.109.jpg: 384x640 2 fires, 51.6ms
Speed: 4.9ms preprocess, 51.6ms inference, 168.1ms postprocess per image at shape (1, 3, 384, 640)
Results saved to runs/detect/predict2
πŸ’‘ Learn more at https://docs.ultralytics.com/modes/predict
InΒ [21]:
output_image_path = "/kaggle/working/runs/detect/predict2/fire.109.jpg"  
output_image = cv2.imread(output_image_path)
output_image = cv2.cvtColor(output_image, cv2.COLOR_BGR2RGB) 
plt.figure(figsize=(8, 8))
plt.imshow(output_image)
plt.title('Detected Image - fire.109.jpg')
plt.axis('off') 
plt.show()
No description has been provided for this image
InΒ [22]:
!yolo predict model="/kaggle/working/runs/detect/train/weights/best.pt", source="/kaggle/input/dataaa88/download (4).jpeg"
WARNING ⚠️ argument 'model=/kaggle/working/runs/detect/train/weights/best.pt,' does not require trailing comma ',', updating to 'model=/kaggle/working/runs/detect/train/weights/best.pt'.
Ultralytics 8.3.126 πŸš€ Python-3.10.14 torch-2.4.0 CUDA:0 (Tesla P100-PCIE-16GB, 16269MiB)
Model summary (fused): 72 layers, 11,126,358 parameters, 0 gradients, 28.4 GFLOPs

image 1/1 /kaggle/input/dataaa88/download (4).jpeg: 416x640 1 smoke, 39.0ms
Speed: 6.3ms preprocess, 39.0ms inference, 155.5ms postprocess per image at shape (1, 3, 416, 640)
Results saved to runs/detect/predict3
πŸ’‘ Learn more at https://docs.ultralytics.com/modes/predict

doneΒΆ

try to change layer of yolo by add c2f layerΒΆ

InΒ [3]:
 !yolo train model='/kaggle/input/yoloyw/other/default/1/yolov8.yaml' data='/kaggle/working/smokeandfire-2/data.yaml' epochs=120 imgsz=640 batch=32 augment=True lr0=0.005 lrf=0.01 weight_decay=0.0005 optimizer=SGD mosaic=True hsv_h=0.015 hsv_s=0.7 hsv_v=0.4 degrees=15 translate=0.1 scale=0.5 shear=0.2 flipud=0.5 fliplr=0.5 mixup=0.2
WARNING ⚠️ no model scale passed. Assuming scale='n'.
Ultralytics 8.3.130 πŸš€ Python-3.10.14 torch-2.4.0 CUDA:0 (Tesla P100-PCIE-16GB, 16269MiB)
engine/trainer: agnostic_nms=False, amp=True, augment=True, auto_augment=randaugment, batch=32, bgr=0.0, box=7.5, cache=False, cfg=None, classes=None, close_mosaic=10, cls=0.5, conf=None, copy_paste=0.0, copy_paste_mode=flip, cos_lr=False, cutmix=0.0, data=/kaggle/working/smokeandfire-2/data.yaml, degrees=15, deterministic=True, device=None, dfl=1.5, dnn=False, dropout=0.0, dynamic=False, embed=None, epochs=120, erasing=0.4, exist_ok=False, fliplr=0.5, flipud=0.5, format=torchscript, fraction=1.0, freeze=None, half=False, hsv_h=0.015, hsv_s=0.7, hsv_v=0.4, imgsz=640, int8=False, iou=0.7, keras=False, kobj=1.0, line_width=None, lr0=0.005, lrf=0.01, mask_ratio=4, max_det=300, mixup=0.2, mode=train, model=/kaggle/input/yoloyw/other/default/1/yolov8.yaml, momentum=0.937, mosaic=True, multi_scale=False, name=train, nbs=64, nms=False, opset=None, optimize=False, optimizer=SGD, overlap_mask=True, patience=100, perspective=0.0, plots=True, pose=12.0, pretrained=True, profile=False, project=None, rect=False, resume=False, retina_masks=False, save=True, save_conf=False, save_crop=False, save_dir=runs/detect/train, save_frames=False, save_json=False, save_period=-1, save_txt=False, scale=0.5, seed=0, shear=0.2, show=False, show_boxes=True, show_conf=True, show_labels=True, simplify=True, single_cls=False, source=None, split=val, stream_buffer=False, task=detect, time=None, tracker=botsort.yaml, translate=0.1, val=True, verbose=True, vid_stride=1, visualize=False, warmup_bias_lr=0.1, warmup_epochs=3.0, warmup_momentum=0.8, weight_decay=0.0005, workers=8, workspace=None
Downloading https://ultralytics.com/assets/Arial.ttf to '/root/.config/Ultralytics/Arial.ttf'...
100%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| 755k/755k [00:00<00:00, 39.1MB/s]
WARNING ⚠️ no model scale passed. Assuming scale='n'.

                   from  n    params  module                                       arguments                     
  0                  -1  1       464  ultralytics.nn.modules.conv.Conv             [3, 16, 3, 2]                 
  1                  -1  1      1888  ultralytics.nn.modules.block.C2f             [16, 16, 1, True]             
  2                  -1  1      4672  ultralytics.nn.modules.conv.Conv             [16, 32, 3, 2]                
  3                  -1  1      7360  ultralytics.nn.modules.block.C2f             [32, 32, 1, True]             
  4                  -1  1     18560  ultralytics.nn.modules.conv.Conv             [32, 64, 3, 2]                
  5                  -1  2     49664  ultralytics.nn.modules.block.C2f             [64, 64, 2, True]             
  6                  -1  1     73984  ultralytics.nn.modules.conv.Conv             [64, 128, 3, 2]               
  7                  -1  2    197632  ultralytics.nn.modules.block.C2f             [128, 128, 2, True]           
  8                  -1  1    295424  ultralytics.nn.modules.conv.Conv             [128, 256, 3, 2]              
  9                  -1  1    460288  ultralytics.nn.modules.block.C2f             [256, 256, 1, True]           
 10                  -1  1    164608  ultralytics.nn.modules.block.SPPF            [256, 256, 5]                 
 11                  -1  1         0  torch.nn.modules.upsampling.Upsample         [None, 2, 'nearest']          
 12             [-1, 6]  1         0  ultralytics.nn.modules.conv.Concat           [1]                           
 13                  -1  1    148224  ultralytics.nn.modules.block.C2f             [384, 128, 1]                 
 14                  -1  1         0  torch.nn.modules.upsampling.Upsample         [None, 2, 'nearest']          
 15             [-1, 4]  1         0  ultralytics.nn.modules.conv.Concat           [1]                           
 16                  -1  1     37248  ultralytics.nn.modules.block.C2f             [192, 64, 1]                  
 17                  -1  1     36992  ultralytics.nn.modules.conv.Conv             [64, 64, 3, 2]                
 18            [-1, 12]  1         0  ultralytics.nn.modules.conv.Concat           [1]                           
 19                  -1  1    156416  ultralytics.nn.modules.block.C2f             [448, 128, 1]                 
 20                  -1  1    147712  ultralytics.nn.modules.conv.Conv             [128, 128, 3, 2]              
 21             [-1, 9]  1         0  ultralytics.nn.modules.conv.Concat           [1]                           
 22                  -1  1    493056  ultralytics.nn.modules.block.C2f             [384, 256, 1]                 
 23        [15, 18, 21]  1   3481942  ultralytics.nn.modules.head.Detect           [2, [192, 448, 384]]          
YOLOv8 summary: 137 layers, 5,776,134 parameters, 5,776,118 gradients, 21.7 GFLOPs

Freezing layer 'model.23.dfl.conv.weight'
AMP: running Automatic Mixed Precision (AMP) checks...
Downloading https://github.com/ultralytics/assets/releases/download/v8.3.0/yolo11n.pt to 'yolo11n.pt'...
100%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| 5.35M/5.35M [00:00<00:00, 176MB/s]
AMP: checks passed βœ…
train: Fast image access βœ… (ping: 0.0Β±0.0 ms, read: 1454.3Β±594.5 MB/s, size: 53.8 KB)
train: Scanning /kaggle/working/smokeandfire-2/train/labels... 8243 images, 11 b
train: New cache created: /kaggle/working/smokeandfire-2/train/labels.cache
WARNING ⚠️ Box and segment counts should be equal, but got len(segments) = 12, len(boxes) = 16365. To resolve this only boxes will be used and all segments will be removed. To avoid this please supply either a detect or segment dataset, not a detect-segment mixed dataset.
albumentations: Blur(p=0.01, blur_limit=(3, 7)), MedianBlur(p=0.01, blur_limit=(3, 7)), ToGray(p=0.01, num_output_channels=3, method='weighted_average'), CLAHE(p=0.01, clip_limit=(1.0, 4.0), tile_grid_size=(8, 8))
val: Fast image access βœ… (ping: 0.0Β±0.0 ms, read: 648.9Β±385.1 MB/s, size: 40.7 KB)
val: Scanning /kaggle/working/smokeandfire-2/valid/labels... 1062 images, 3 back
val: New cache created: /kaggle/working/smokeandfire-2/valid/labels.cache
Plotting labels to runs/detect/train/labels.jpg... 
optimizer: SGD(lr=0.005, momentum=0.937) with parameter groups 61 weight(decay=0.0), 68 weight(decay=0.0005), 67 bias(decay=0.0)
Image sizes 640 train, 640 val
Using 4 dataloader workers
Logging results to runs/detect/train
Starting training for 120 epochs...

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      1/120      5.96G       3.36       3.73       3.79         62        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.515      0.061    0.00815    0.00331

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      2/120      5.98G      3.049      3.223      3.348         92        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.284      0.161     0.0903      0.025

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      3/120         6G      2.478      2.922      2.903         72        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.389      0.301       0.24     0.0874

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      4/120      5.99G      2.089      2.575      2.519         90        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.669      0.459      0.502      0.256

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      5/120         6G      1.945       2.37      2.351         69        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.739      0.572      0.627      0.329

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      6/120      5.99G      1.845      2.215      2.246         65        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.74      0.618      0.656      0.382

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      7/120      6.01G      1.798      2.135      2.203         70        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.756      0.628      0.678      0.412

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      8/120      5.98G      1.758      2.095      2.158         71        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.795       0.61      0.653      0.405

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
      9/120         6G      1.719       2.03      2.118         69        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.789      0.682      0.719      0.447

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     10/120      5.99G      1.697      2.007      2.092         85        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.764      0.665      0.711      0.454

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     11/120         6G      1.666      1.953      2.054         87        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.792      0.676      0.717      0.463

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     12/120      5.98G      1.642      1.907      2.025         77        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.796      0.705       0.75      0.511

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     13/120         6G      1.627      1.876      2.012         87        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.817      0.698      0.757      0.504

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     14/120      5.98G      1.596      1.834      1.985         70        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.837      0.714      0.762      0.513

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     15/120         6G       1.59      1.829      1.977         90        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.823      0.726      0.766      0.531

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     16/120      5.98G      1.573      1.801      1.959        111        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.828      0.735      0.771      0.542

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     17/120         6G       1.56      1.766      1.946         64        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.838      0.729       0.77      0.528

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     18/120      5.98G      1.549      1.742      1.939         65        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.834      0.734      0.774      0.544

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     19/120         6G      1.542      1.729      1.936         75        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.838      0.744      0.788      0.538

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     20/120      5.98G      1.523      1.699      1.918         92        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.852      0.752      0.794      0.551

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     21/120         6G      1.511      1.685      1.905         91        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.822      0.757      0.798      0.563

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     22/120      5.98G      1.511      1.676      1.906        107        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.839       0.75      0.792      0.558

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     23/120         6G      1.496      1.667      1.904        117        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.841      0.771        0.8      0.573

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     24/120      5.98G      1.502      1.667      1.898         87        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.853      0.758      0.801      0.565

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     25/120         6G      1.474      1.638       1.88         66        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.848       0.76      0.798      0.565

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     26/120      5.98G       1.49      1.649      1.884         88        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.862      0.771      0.804      0.564

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     27/120         6G      1.461      1.613       1.86         77        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.856      0.774      0.811      0.579

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     28/120      5.98G      1.453        1.6      1.849         79        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.87       0.78      0.818      0.577

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     29/120         6G      1.453       1.59      1.847        119        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.852       0.78      0.815      0.579

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     30/120      5.98G       1.46      1.592      1.854         81        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.87      0.793       0.82      0.586

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     31/120         6G      1.441      1.559      1.836         85        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.852      0.784      0.816      0.591

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     32/120      5.98G      1.431      1.551      1.829         91        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.873      0.781      0.815      0.582

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     33/120         6G      1.433      1.556      1.827         78        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.859      0.795      0.829      0.598

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     34/120      5.98G      1.435      1.541      1.828         83        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.868      0.789      0.817      0.589

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     35/120         6G      1.424      1.532      1.821         52        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.874      0.796       0.83      0.604

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     36/120      5.98G      1.407      1.519      1.809         80        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.87      0.797      0.825        0.6

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     37/120         6G      1.421      1.534      1.823         80        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.854      0.799      0.823      0.602

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     38/120      5.98G      1.413      1.524      1.809         82        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.86      0.798      0.828      0.609

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     39/120         6G      1.421       1.53      1.821         73        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.872      0.798      0.828      0.601

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     40/120      5.98G      1.413      1.506      1.808         75        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.886      0.795      0.833      0.609

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     41/120         6G       1.42       1.53      1.815         87        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.862      0.815       0.84      0.606

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     42/120      5.98G      1.397      1.488      1.796        103        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.876      0.812      0.832      0.608

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     43/120         6G      1.386      1.469      1.789         86        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.871      0.805      0.831      0.611

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     44/120      5.98G       1.39       1.46      1.786         76        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.871      0.806       0.83      0.615

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     45/120         6G      1.386      1.459      1.787         89        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.869      0.797      0.828      0.615

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     46/120      5.98G      1.394      1.473      1.788         90        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.888      0.807      0.837      0.616

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     47/120         6G      1.384      1.477      1.788         89        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.885      0.812      0.839      0.615

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     48/120      5.98G      1.384      1.465      1.784        105        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.88      0.807      0.837      0.617

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     49/120         6G      1.372      1.442       1.77         87        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.877      0.813      0.838       0.62

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     50/120      5.98G       1.37      1.431      1.765         81        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081       0.88      0.822      0.839      0.624

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     51/120         6G      1.364      1.433      1.767        116        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.872      0.821      0.842      0.622

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     52/120      5.98G       1.36      1.434      1.762         56        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.875      0.818      0.842      0.627

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     53/120         6G      1.371       1.44      1.769         92        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.884      0.817      0.846      0.626

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     54/120      5.98G      1.366      1.425      1.757         71        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.875      0.825      0.844      0.622

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     55/120         6G      1.341      1.406      1.747         67        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.875      0.832      0.842      0.628

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     56/120      5.98G       1.36      1.423      1.762         99        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.886      0.817      0.846      0.627

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     57/120         6G      1.347      1.409      1.749         81        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.879      0.822      0.845       0.63

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     58/120      5.98G      1.363      1.415      1.761        101        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.885      0.812       0.84      0.628

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     59/120         6G      1.349        1.4      1.748        101        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.879      0.825      0.843      0.628

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     60/120      5.98G      1.351      1.411      1.749         89        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.879      0.818      0.846      0.628

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     61/120         6G      1.349      1.399      1.745         87        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.878      0.821      0.841      0.627

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     62/120      5.98G      1.341       1.38      1.738         77        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.881      0.824      0.844       0.63

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     63/120         6G       1.35      1.399      1.745         68        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.881      0.823      0.843      0.633

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     64/120      5.98G      1.329       1.37      1.727         67        640: 1
                 Class     Images  Instances      Box(P          R      mAP50  m
                   all       1062       2081      0.883      0.819      0.844      0.633

      Epoch    GPU_mem   box_loss   cls_loss   dfl_loss  Instances       Size
     65/120         6G      1.339      1.384      1.739        134        640:  ^C
     65/120         6G      1.339      1.384      1.739        134        640:  
InΒ [Β ]:
# there is no improvement so as it 
InΒ [Β ]:
 
InΒ [Β ]: